From: Eddie James <eajames@linux.ibm.com>
To: Jonathan Cameron <jic23@kernel.org>
Cc: linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org,
joel@jms.id.au, pmeerw@pmeerw.net, lars@metafoo.de,
knaack.h@gmx.de
Subject: Re: [PATCH v2 1/3] iio: Add driver for Infineon DPS310
Date: Wed, 15 May 2019 13:46:46 -0500 [thread overview]
Message-ID: <cf108058-dd50-4651-6c97-a5c7e82ef085@linux.ibm.com> (raw)
In-Reply-To: <20190511102236.4c5f9585@archlinux>
On 5/11/19 4:22 AM, Jonathan Cameron wrote:
> On Wed, 8 May 2019 14:35:26 -0500
> Eddie James <eajames@linux.ibm.com> wrote:
>
>> From: Joel Stanley <joel@jms.id.au>
>>
>> The DPS310 is a temperature and pressure sensor. It can be accessed over
>> i2c and SPI.
>>
>> Signed-off-by: Eddie James <eajames@linux.ibm.com>
> Hi Eddie,
>
> Ideally we'll get a sign off form Joel as well on this.
>
> A few comments inline.
>
> I 'think' this is probably fine without any locking to prevent simultaneous reads
> and /or writes to the registers because the few functions that do multiple reads
> and writes look fine. Please do take another look at that though to confirm there
> are no corner cases.
>
> Otherwise there is a race in the remove path that needs fixing.
> Various minor bits and bobs inline.
>
> thanks,
>
> Jonathan
>
>
>
>> ---
>> MAINTAINERS | 6 +
>> drivers/iio/pressure/Kconfig | 10 +
>> drivers/iio/pressure/Makefile | 1 +
>> drivers/iio/pressure/dps310.c | 429 ++++++++++++++++++++++++++++++++++++++++++
>> 4 files changed, 446 insertions(+)
>> create mode 100644 drivers/iio/pressure/dps310.c
>>
>> +};
>> +MODULE_DEVICE_TABLE(i2c, dps310_id);
>> +
>> +static const unsigned short normal_i2c[] = {
>> + 0x77, 0x76, I2C_CLIENT_END
>> +};
>> +
>> +static struct i2c_driver dps310_driver = {
>> + .driver = {
>> + .name = "dps310",
>> + },
>> + .probe = dps310_probe,
>> + .remove = dps310_remove,
>> + .address_list = normal_i2c,
> I'm fairly sure the address list is only used along with the detection
> infrastructure. As such it doesn't actually provide any value unless
> you have a detect callback. Please remove.
>
> I would like to see a DT and/or ACPI binding though as that is the
> means most people will use to find the device.
Somehow the device is already present in the witherspoon device tree
where it's currently being used, so I don't have anything to add.
arch/arm/boot/dts/aspeed-bmc-opp-witherspoon.dts
Thanks,
Eddie
>
>> + .id_table = dps310_id,
>> +};
>> +module_i2c_driver(dps310_driver);
>> +
>> +MODULE_AUTHOR("Joel Stanley <joel@jms.id.au>");
>> +MODULE_DESCRIPTION("Infineon DPS310 pressure and temperature sensor");
>> +MODULE_LICENSE("GPL v2");
next prev parent reply other threads:[~2019-05-15 18:47 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-05-08 19:35 [PATCH v2 0/3] iio: Add driver for Infineon DPS310 Eddie James
2019-05-08 19:35 ` [PATCH v2 1/3] " Eddie James
2019-05-11 9:22 ` Jonathan Cameron
2019-05-15 18:46 ` Eddie James [this message]
2019-05-18 8:46 ` Jonathan Cameron
2019-05-08 19:35 ` [PATCH v2 2/3] iio: dps310: Temperature measurement errata Eddie James
2019-05-09 3:09 ` Matt Ranostay
2019-05-09 15:17 ` Eddie James
2019-05-10 2:21 ` Matt Ranostay
2019-05-08 19:35 ` [PATCH v2 3/3] iio: dps310: Add pressure sensing capability Eddie James
2019-05-11 9:48 ` Jonathan Cameron
2019-05-14 20:25 ` Eddie James
2019-05-18 8:47 ` Jonathan Cameron
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=cf108058-dd50-4651-6c97-a5c7e82ef085@linux.ibm.com \
--to=eajames@linux.ibm.com \
--cc=jic23@kernel.org \
--cc=joel@jms.id.au \
--cc=knaack.h@gmx.de \
--cc=lars@metafoo.de \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=pmeerw@pmeerw.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox