[PATCH] mtd: spi-nor: Decouple SPI NOR's device_node from controller device

Jonas Gorski jogo at openwrt.org
Fri Aug 21 13:49:46 PDT 2015


On Fri, Aug 21, 2015 at 8:34 PM, Marek Vasut <marex at denx.de> wrote:
> On Friday, August 21, 2015 at 04:15:11 PM, Jonas Gorski wrote:
>> > This patch is inspired by 5844feeaa4154d1c46d3462c7a4653d22356d8b4
>> > mtd: nand: add common DT init code
>>
>> I know that this commit named it dn for nand, but IMHO "dn" isn't a
>> very readable member name, so I would suggest using something with
>> "node" in it (just using of_node as well seems to be common). I see no
>> place where the name length might become an issue.
>
> I thought .dn was supposed to be abbrev for device_node ;-)

Sure, if you know what it is supposed to stand for it is obvious ;-).
And from a "stylistic" point of view, struct spi_nor has members
called page_size, flash_read or cmd_buf and not ps, fr, or cb so using
dn instead of e.g. dev_node seems a bit odd.


Jonas



More information about the linux-mtd mailing list