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]
Message-ID: <20140317131453.GF11706@sirena.org.uk>
Date:	Mon, 17 Mar 2014 13:14:53 +0000
From:	Mark Brown <broonie@...nel.org>
To:	Rob Herring <robherring2@...il.com>
Cc:	Harini Katakam <harinik@...inx.com>,
	Rob Herring <robh+dt@...nel.org>,
	Pawel Moll <pawel.moll@....com>,
	Mark Rutland <mark.rutland@....com>,
	Ian Campbell <ijc+devicetree@...lion.org.uk>,
	Kumar Gala <galak@...eaurora.org>,
	Rob Landley <rob@...dley.net>,
	Grant Likely <grant.likely@...aro.org>,
	"devicetree@...r.kernel.org" <devicetree@...r.kernel.org>,
	"linux-doc@...r.kernel.org" <linux-doc@...r.kernel.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	"linux-spi@...r.kernel.org" <linux-spi@...r.kernel.org>,
	michals@...inx.com
Subject: Re: [PATCH] SPI: Add driver for Cadence SPI controller

On Mon, Mar 17, 2014 at 07:47:24AM -0500, Rob Herring wrote:

Please delete irrelevant context from your replies, it makes it easier
to find the new content.

> On Mon, Mar 17, 2014 at 7:05 AM, Harini Katakam <harinik@...inx.com> wrote:

> > +/* Macros for the SPI controller read/write */
> > +#define cdns_spi_read(addr)    readl_relaxed(addr)
> > +#define cdns_spi_write(addr, val)      writel_relaxed((val), (addr))

> Just use readl/writel directly.

Or make them static inline structures which take the driver data
structure and an offset within the register map for the device and do
the maths to resolve the actual address.

> > +static SIMPLE_DEV_PM_OPS(cdns_spi_dev_pm_ops, cdns_spi_suspend,
> > +                        cdns_spi_resume);

> > +/* Work with hotplug and coldplug */
> > +MODULE_ALIAS("platform:" CDNS_SPI_NAME);

> Not sure, but I don't think this should be needed.

It won't be used by DT systems but it is good practice, especially with
something like this that clearly is a generic IP which could be used on
non-DT systems too (it's not like it costs anything meaningful).

Download attachment "signature.asc" of type "application/pgp-signature" (837 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ