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  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]
Date:   Thu, 23 Feb 2017 18:58:12 +0200
From:   Andy Shevchenko <andy.shevchenko@...il.com>
To:     Lars-Peter Clausen <lars@...afoo.de>
Cc:     Eva Rachel Retuya <eraretuya@...il.com>,
        Jonathan Cameron <jic23@...nel.org>, linux-iio@...r.kernel.org,
        Hartmut Knaack <knaack.h@....de>,
        Peter Meerwald <pmeerw@...erw.net>,
        Dmitry Torokhov <dmitry.torokhov@...il.com>,
        Michael Hennerich <michael.hennerich@...log.com>,
        Daniel Baluta <daniel.baluta@...il.com>,
        Alison Schofield <amsfield22@...il.com>,
        Florian Vaussard <florian.vaussard@...g-vd.ch>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        Rob Herring <robh+dt@...nel.org>,
        Mark Rutland <mark.rutland@....com>,
        devicetree <devicetree@...r.kernel.org>
Subject: Re: [PATCH v3 4/4] iio: accel: adxl345: Add SPI support

On Thu, Feb 23, 2017 at 6:47 PM, Lars-Peter Clausen <lars@...afoo.de> wrote:
> On 02/23/2017 05:43 PM, Andy Shevchenko wrote:
>> On Wed, Feb 22, 2017 at 12:23 PM, Eva Rachel Retuya <eraretuya@...il.com> wrote:
>>> Add SPI driver that initializes SPI regmap for the adxl345 core driver.
>>> The driver supports the same functionality as I2C namely the x, y, z and
>>> scale readings.

>>>  config ADXL345_I2C
>>>         tristate
>>>         select REGMAP_I2C
>>>
>>> +config ADXL345_SPI
>>> +       tristate
>>> +       select REGMAP_SPI
>>
>> Hmm...
>> I saw another pattern
>>
>> Library / core part is non-visible to user, while
>> SPI and I2C parts are selectable by user.
>>
>> Why do you use inverted pattern? What did I miss?
>
> The first version of the patch used the other pattern SPI/I2C visible.
> Jonathan suggested this other pattern. I prefer the explicit SPI/I2C visible
> pattern, but in the end it doesn't really matter as long as both work.

Yes, but this pattern makes extra footprint of the kernel and
basically dead code when I would like, for example, to have SPI bus
enabled, I2C module available, but SPI module not compiled.

Other one is when I want to have one compiled in, one as a module by
whatever reason.

At the end I have no strong opinion, though rationale for the opposite is above.

-- 
With Best Regards,
Andy Shevchenko

Powered by blists - more mailing lists