lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <MN2PR12MB44228DEA7CE19B853292FE38C4CC0@MN2PR12MB4422.namprd12.prod.outlook.com>
Date:   Fri, 27 Mar 2020 10:52:02 +0000
From:   Jean-Baptiste Maneyrol <JManeyrol@...ensense.com>
To:     Wolfram Sang <wsa+renesas@...g-engineering.com>,
        "linux-i2c@...r.kernel.org" <linux-i2c@...r.kernel.org>
CC:     Jonathan Cameron <jic23@...nel.org>,
        Hartmut Knaack <knaack.h@....de>,
        Lars-Peter Clausen <lars@...afoo.de>,
        Peter Meerwald-Stadler <pmeerw@...erw.net>,
        "linux-iio@...r.kernel.org" <linux-iio@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 1/1] iio: imu: inv_mpu6050: convert to use
 i2c_new_client_device()

Hello,

thanks for the patch.
Looks good for me.

Acked-by: Jean-Baptiste Maneyrol <jmaneyrol@...ensense.com>

Best regards,
JB


From: linux-iio-owner@...r.kernel.org <linux-iio-owner@...r.kernel.org> on behalf of Wolfram Sang <wsa+renesas@...g-engineering.com>

Sent: Thursday, March 26, 2020 22:09

To: linux-i2c@...r.kernel.org <linux-i2c@...r.kernel.org>

Cc: Wolfram Sang <wsa+renesas@...g-engineering.com>; Jonathan Cameron <jic23@...nel.org>; Hartmut Knaack <knaack.h@....de>; Lars-Peter Clausen <lars@...afoo.de>; Peter Meerwald-Stadler <pmeerw@...erw.net>; linux-iio@...r.kernel.org <linux-iio@...r.kernel.org>;
 linux-kernel@...r.kernel.org <linux-kernel@...r.kernel.org>

Subject: [PATCH 1/1] iio: imu: inv_mpu6050: convert to use i2c_new_client_device()

 


 CAUTION: This email originated from outside of the organization. Please make sure the sender is who they say they are and do not click links or open attachments unless you recognize the sender and know the content is safe.



Move away from the deprecated API and return the shiny new ERRPTR where

useful.



Signed-off-by: Wolfram Sang <wsa+renesas@...g-engineering.com>

---

 drivers/iio/imu/inv_mpu6050/inv_mpu_acpi.c | 8 +++++---

 1 file changed, 5 insertions(+), 3 deletions(-)



diff --git a/drivers/iio/imu/inv_mpu6050/inv_mpu_acpi.c b/drivers/iio/imu/inv_mpu6050/inv_mpu_acpi.c

index 2f8560ba4572..c27d06035c8b 100644

--- a/drivers/iio/imu/inv_mpu6050/inv_mpu_acpi.c

+++ b/drivers/iio/imu/inv_mpu6050/inv_mpu_acpi.c

@@ -135,6 +135,7 @@ int inv_mpu_acpi_create_mux_client(struct i2c_client *client)

         st->mux_client = NULL;

         if (ACPI_HANDLE(&client->dev)) {

                 struct i2c_board_info info;

+               struct i2c_client *mux_client;

                 struct acpi_device *adev;

                 int ret = -1;

 

@@ -172,9 +173,10 @@ int inv_mpu_acpi_create_mux_client(struct i2c_client *client)

                         } else

                                 return 0; /* no secondary addr, which is OK */

                 }

-               st->mux_client = i2c_new_device(st->muxc->adapter[0], &info);

-               if (!st->mux_client)

-                       return -ENODEV;

+               mux_client = i2c_new_client_device(st->muxc->adapter[0], &info);

+               if (IS_ERR(mux_client))

+                       return PTR_ERR(mux_client);

+               st->mux_client = mux_client;

         }

 

         return 0;

-- 

2.20.1



Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ