Re: [PATCH 1/6] gpio: make the gpiochip a real device

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Nov 02, 2015 at 01:43:23PM +0100, Johan Hovold wrote:
> On Mon, Nov 02, 2015 at 12:25:14PM +0000, Mark Brown wrote:

> > > First of all, you must never register the same device structure twice.

> > Well, you can unregister and reregister (and it is reasonable practice
> > to make sure that the struct isn't full of noise) - we usually allocate
> > things out of kzalloc().

> Actually, no. It's an explicitly forbidden practise to reregister the
> same struct device.

A memset() should be enough, if not then we have problems with any
dynamically allocated struct device.

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux