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]
Date:	Thu, 28 Apr 2016 22:37:57 +0300
From:	Octavian Purdila <octavian.purdila@...el.com>
To:	Mark Brown <broonie@...nel.org>
Cc:	"Rafael J. Wysocki" <rjw@...ysocki.net>,
	Len Brown <lenb@...nel.org>,
	Matt Fleming <matt@...eblueprint.co.uk>,
	Wolfram Sang <wsa@...-dreams.de>,
	Joel Becker <jlbec@...lplan.org>,
	"linux-acpi@...r.kernel.org" <linux-acpi@...r.kernel.org>,
	linux-efi@...r.kernel.org, linux-i2c <linux-i2c@...r.kernel.org>,
	linux-spi <linux-spi@...r.kernel.org>,
	lkml <linux-kernel@...r.kernel.org>,
	Irina Tirdea <irina.tirdea@...el.com>
Subject: Re: [RFC PATCH v2 06/10] spi: add support for ACPI reconfigure notifications

On Thu, Apr 28, 2016 at 8:42 PM, Mark Brown <broonie@...nel.org> wrote:
> On Wed, Apr 20, 2016 at 01:39:04AM +0300, Octavian Purdila wrote:
>
>> +     switch (value) {
>> +     case ACPI_RECONFIG_DEVICE_ADD:
>> +             master = acpi_spi_find_master_by_adev(adev->parent);
>> +             if (!master)
>> +                     break;
>> +
>> +             acpi_register_spi_device(master, adev);
>> +             put_device(&master->dev);
>> +             break;
>> +     case ACPI_RECONFIG_DEVICE_REMOVE:
>> +             spi = acpi_spi_find_device_by_adev(adev);
>> +             if (!spi)
>> +                     break;
>
> There's more code here now than I remember but this all looks *really*
> close to the DT code except for the OF_POPULATED flag that we set when
> things are instantiated in DT.  The duplication seems bad but the fact
> that we're missing the flag worries me...  do we have guarantees that
> ACPI won't double register?

We use the adev->flags.visited to check when a device has been already
enumerated, and we skip registering a new SPI slave in that case.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ