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, 26 Aug 2010 10:34:58 -0700 (PDT)
From:	David Brownell <david-b@...bell.net>
To:	Alan Cox <alan@...rguk.ukuu.org.uk>
Cc:	Anton Vorontsov <cbouatmailru@...il.com>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Samuel Ortiz <sameo@...ux.intel.com>,
	Mark Brown <broonie@...nsource.wolfsonmicro.com>,
	David Brownell <dbrownell@...rs.sourceforge.net>,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] gpio: Add generic driver for simple memory mapped controllers



--- On Thu, 8/26/10, Alan Cox <alan@...rguk.ukuu.org.uk> wrote:

> > Just rename it to match the IP block used.
> 
> There are zillions of IP blocks that have that interface,

If there are "zillions" that suggests the HW
engineers have version/naming issues just like
certain software engineers.  Only goes to show
how close Verilog and VHDL are to software! :)


> how exactly do
> you propose to rename it.

My suggestion was to use the name provided/used
by the hardware engineers.  (E.g. whatever the
Verilog or VHDL equivalent of a module name is.)

So -- NO RENAME -- except for the driver.

If I understand you correctly, those engineers
are not reusing a named module; they are at best
just copying/pasting some Verilog/VHDL and adding
ASIC/SoC/.../FPGA-specific hacks.  (Which calls into
question just how much assurance there can be that
one driver will work reliably for all instances...


> > That removes all confusion.  Engineers will
> >  be able to know more easily whether this
> > driver is even relevant to them.
> 
> Not unless its got a name about 1000 characters long
> listing all the
> devices it might drive - and changes name weekly.

Someone should have a few words with those hardware
engineers about module naming and consistency, so
software doesn't need to work around such issues.

Such problems have been solved for decades, and
there's no reason to create confusion higher up
the system stack.  (or force workarounds.)


> > An example might be "amba-9999 (a made-up
> > number, likely not matching a GPIO controller).

Note that such names are already used in Linux
with IP blocks from AMBA; Designware blocks, as
I noted, aren't dissimilar (dw_foo.c in at least
a few cases).

> What's wrong with a sensible generic name like
> gpio-mmio-table ?


That's a much better name.  I'ts got technical
content, even!  (vs "simple" being "marketing",
including easy confusion with other entities).

All I'll say is that it might
 be *too* generic a name.  I know I can come up
with current examples of GPIO done via MMIO
(tables) that this driver won't fit at all.
That can probably be worked around via docs and
conventions.

There'd need to be good docs on what this
gpio-mmio-table interface expects.  Some of that
belongs in Kconfig, not much; mostly I'd think
it belongs in driver header comments, but also
some in the patch comment itself.  I hear you
strongly implying that there's no generic hardware
doc to reference.  (As theree would be if this
block came from the AMBA or DesignWare families.)




--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ