[PATCH] I2C: Kill i2c_client.id (5/5)

From: Greg KH (greg_at_kroah.com)
Date: 03/04/05

  • Next message: Wen Xiong: "Re: [ patch 1/7] drivers/serial/jsm: new serial device driver"
    Date:	Fri, 4 Mar 2005 12:36:34 -0800
    To: linux-kernel@vger.kernel.org, sensors@Stimpy.netroedge.com
    
    

    ChangeSet 1.2087, 2005/03/02 11:58:29-08:00, khali@linux-fr.org

    [PATCH] I2C: Kill i2c_client.id (5/5)

    > (5/5) Documentation update.

    Finally, updates are required to the i2c/writing-client and
    i2c/porting-client documents. Remove any reference to i2c_client id and
    invite porters to discard that struct member.

    Signed-off-by: Jean Delvare <khali@linux-fr.org>
    Signed-off-by: Greg Kroah-Hartman <greg@kroah.com>

     Documentation/i2c/porting-clients | 6 +++---
     Documentation/i2c/writing-clients | 4 ----
     2 files changed, 3 insertions(+), 7 deletions(-)

    diff -Nru a/Documentation/i2c/porting-clients b/Documentation/i2c/porting-clients
    --- a/Documentation/i2c/porting-clients 2005-03-04 12:25:58 -08:00
    +++ b/Documentation/i2c/porting-clients 2005-03-04 12:25:58 -08:00
    @@ -49,9 +49,8 @@
       static void lm75_update_client(struct i2c_client *client);
     
     * [Sysctl] All sysctl stuff is of course gone (defines, ctl_table
    - and functions). Instead, right after the static id definition
    - line, you have to define show and set functions for each sysfs
    - file. Only define set for writable values. Take a look at an
    + and functions). Instead, you have to define show and set functions for
    + each sysfs file. Only define set for writable values. Take a look at an
       existing 2.6 driver for details (lm78 for example). Don't forget
       to define the attributes for each file (this is that step that
       links callback functions). Use the file names specified in
    @@ -86,6 +85,7 @@
       Replace the sysctl directory registration by calls to
       device_create_file. Move the driver initialization before any
       sysfs file creation.
    + Drop client->id.
     
     * [Init] Limits must not be set by the driver (can be done later in
       user-space). Chip should not be reset default (although a module
    diff -Nru a/Documentation/i2c/writing-clients b/Documentation/i2c/writing-clients
    --- a/Documentation/i2c/writing-clients 2005-03-04 12:25:58 -08:00
    +++ b/Documentation/i2c/writing-clients 2005-03-04 12:25:58 -08:00
    @@ -344,9 +344,6 @@
     
     For now, you can ignore the `flags' parameter. It is there for future use.
     
    - /* Unique ID allocation */
    - static int foo_id = 0;
    -
       int foo_detect_client(struct i2c_adapter *adapter, int address,
                             unsigned short flags, int kind)
       {
    @@ -482,7 +479,6 @@
         data->type = kind;
         /* SENSORS ONLY END */
     
    - new_client->id = foo_id++; /* Automatically unique */
         data->valid = 0; /* Only if you use this field */
         init_MUTEX(&data->update_lock); /* Only if you use this field */
     

    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/


  • Next message: Wen Xiong: "Re: [ patch 1/7] drivers/serial/jsm: new serial device driver"

    Relevant Pages

    • [PATCH 2.6] I2C: Kill i2c_client.id (5/5)
      ... > Documentation update. ... * [Sysctl] All sysctl stuff is of course gone (defines, ... existing 2.6 driver for details. ... sysfs file creation. ...
      (Linux-Kernel)
    • RE: [patch 2.6.12-rc3] dell_rbu: Resubmitting patch for new DellBIOS update driver
      ... > from your module init function. ... In this driver it is called when the user ... Don't we need to have a sysfs file ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)
    • Re: [GIT PATCH] PCI patches for 2.6.15 - retry
      ... or driver core. ... the bottom of the barrier/md bug and just before I hit this with -mm3 which I believe is the same bug. ... last sysfs file: ... To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/ ...
      (Linux-Kernel)
    • Re: usb sysfs intf files no longer created when probe fails
      ... > to the previous failure to create the sysfs file: ... Sounds like a bug in that driver, care to ask the authors of it about ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)
    • Re: if_ath breaks s3 suspend/resume [Was: ACPI S3 wakeup problem (beeeeeeeeep)]
      ... Now with this sysctl enabled I hear a continuing beep, but the hard drive stays powered down, also the LCD keeps unlit. ... but sometimes I get a hang during bootup shortly after ath0 is brought up. ... For the hang I'm not sure how to reproduce it. ... not a driver problem. ...
      (freebsd-current)