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] [day] [month] [year] [list]
Message-ID: <20240727132227.4d350534@jic23-huawei>
Date: Sat, 27 Jul 2024 13:22:27 +0100
From: Jonathan Cameron <jic23@...nel.org>
To: wangshuaijie@...nic.com
Cc: conor+dt@...nel.org, devicetree@...r.kernel.org, kangjiajun@...nic.com,
 krzk+dt@...nel.org, lars@...afoo.de, linux-iio@...r.kernel.org,
 linux-kernel@...r.kernel.org, liweilei@...nic.com, robh@...nel.org,
 waqar.hameed@...s.com
Subject: Re: [PATCH V3 2/2] Add support for Awinic proximity sensor


> >> diff --git a/drivers/iio/proximity/aw9610x.c b/drivers/iio/proximity/aw9610x.c
> >> new file mode 100644
> >> index 000000000000..15e53d55d2a1
> >> --- /dev/null
> >> +++ b/drivers/iio/proximity/aw9610x.c
> >> @@ -0,0 +1,1150 @@
> >> +// SPDX-License-Identifier: GPL-2.0
> >> +/*
> >> + * AWINIC sar sensor driver (aw9610x)
> >> + *
> >> + * Author: Shuaijie Wang<wangshuaijie@...nic.com>
> >> + *
> >> + * Copyright (c) 2024 awinic Technology CO., LTD
> >> + */
> >> +#include "aw_sar.h"
> >> +
> >> +#define AW9610X_I2C_NAME "aw9610x_sar"
> >> +#define AW9610X_CHANNEL_MAX	(5)  
> >
> >No brackets around numeric values. They add nothing.
> >  
> 
> The patch for v4 will fix these issues.

If you agree with a comment, usual convention to save everyone time is
don't reply to it and ideally crop that part of the email out entirely.

It is hard to find the active discussions that need replies in an
email unless it is cropped to make them the only remaining parts.

...


> 
> >> +
> >> +#define AFE_BASE_ADDR					(0x0000)  
> >
> The patch for v4 will fix these issues.
> 
> >> +
> >> +	if (reg_val != AW9610X_CHIP_ID) {
> >> +		dev_err(p_sar->dev, "unsupport dev, chipid is (0x%04x)", reg_val);  
> >
> >
> >To allow use of fallback compatibles in DT we normally accept chipid missmatches.
> >So at most dev_info and carry on anyway.
> >  
> 
> Sorry, if the chipid does not match, the driver is likely to encounter issues
> during operation. We will not consider compatibility with more devices for
> the time being.

This discussion has been had many times and the standard approach to this has
changed over time (in IIO anyway). We have not yet updated all drivers to
the current policy.

Current policy is that we do not block probing a chip that firmware has told
us is compatible on the basis of a failure to match a chip id.

Print a message to help with any bug report issues you may get.
+ educate integrators of your device that they must not put false compatibles
in their firmware.

> 
> >> +		return -EINVAL;
> >> +	}
> >> +	memcpy(p_sar->chip_name, "AW9610X", 8);
> >> +
> >> +	return 0;
> >> +}
...

> Kind regards,
> Wang Shuaijie


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ