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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250624054508.GA2824380@black.fi.intel.com>
Date: Tue, 24 Jun 2025 08:45:08 +0300
From: Mika Westerberg <mika.westerberg@...ux.intel.com>
To: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
Cc: Randolph Ha <rha051117@...il.com>, linux-i2c@...r.kernel.org,
	linux-acpi@...r.kernel.org, linux-kernel@...r.kernel.org,
	Wolfram Sang <wsa+renesas@...g-engineering.com>,
	Mika Westerberg <westeri@...nel.org>
Subject: Re: [PATCH v1 1/1] i2c: acpi: Replace custom code with
 device_match_acpi_handle()

On Mon, Jun 23, 2025 at 04:45:21PM +0300, Andy Shevchenko wrote:
> Since driver core provides a generic device_match_acpi_handle()
> we may replace the custom code with it.

Well okay but now you replace a simple comparison with a function call. I'm
fine with the patch but I also don't think this is an improvement ;-)

> Signed-off-by: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
> ---
>  drivers/i2c/i2c-core-acpi.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/i2c/i2c-core-acpi.c b/drivers/i2c/i2c-core-acpi.c
> index d2499f302b50..3445cc3b476b 100644
> --- a/drivers/i2c/i2c-core-acpi.c
> +++ b/drivers/i2c/i2c-core-acpi.c
> @@ -250,7 +250,7 @@ static int i2c_acpi_get_info(struct acpi_device *adev,
>  
>  	if (adapter) {
>  		/* The adapter must match the one in I2cSerialBus() connector */
> -		if (ACPI_HANDLE(&adapter->dev) != lookup.adapter_handle)
> +		if (!device_match_acpi_handle(&adapter->dev, lookup.adapter_handle))
>  			return -ENODEV;
>  	} else {
>  		struct acpi_device *adapter_adev;
> -- 
> 2.47.2

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ