All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sourav Poddar <sourav.poddar-l0cyMroinI0@public.gmane.org>
To: Mark Brown <broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
Cc: rnayak-l0cyMroinI0@public.gmane.org,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	Felipe Balbi <balbi-l0cyMroinI0@public.gmane.org>,
	grant.likely-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org,
	spi-devel-general-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org,
	linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCHv2] drivers: spi: Add qspi flash controller
Date: Tue, 2 Jul 2013 15:56:57 +0530	[thread overview]
Message-ID: <51D2AAF1.4080803@ti.com> (raw)
In-Reply-To: <20130702101718.GE27646-GFdadSzt00ze9xe1eoZjHA@public.gmane.org>

Hi Mark,
On Tuesday 02 July 2013 03:47 PM, Mark Brown wrote:
> On Tue, Jul 02, 2013 at 12:44:04PM +0300, Felipe Balbi wrote:
>> On Tue, Jul 02, 2013 at 10:32:47AM +0100, Mark Brown wrote:
>>> Does this hardware really support anything other than 8 bits per word?
>>> There is no code in the driver which pays any attention to the word
>>> size...
>> the HW has a 128-bit shift register ;-) but driver doesn't look
>> complete.
> That's not the issue - remember that SPI specifies big endian byte
> ordering for words on the bus so things will need to be reordered by the
> hardware for anything except 8 bits.
Yes, I defaulted my driver to assume 8 bits.
I will introduce case by case reads based on t->len

Something like..
case 8:
    readb();
case 16:
    readw();
case 32:
    readl();


~Sourav

------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev

WARNING: multiple messages have this Message-ID (diff)
From: Sourav Poddar <sourav.poddar@ti.com>
To: Mark Brown <broonie@kernel.org>
Cc: Felipe Balbi <balbi@ti.com>,
	<spi-devel-general@lists.sourceforge.net>,
	<grant.likely@linaro.org>, <rnayak@ti.com>,
	<linux-omap@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Subject: Re: [PATCHv2] drivers: spi: Add qspi flash controller
Date: Tue, 2 Jul 2013 15:56:57 +0530	[thread overview]
Message-ID: <51D2AAF1.4080803@ti.com> (raw)
In-Reply-To: <20130702101718.GE27646@sirena.org.uk>

Hi Mark,
On Tuesday 02 July 2013 03:47 PM, Mark Brown wrote:
> On Tue, Jul 02, 2013 at 12:44:04PM +0300, Felipe Balbi wrote:
>> On Tue, Jul 02, 2013 at 10:32:47AM +0100, Mark Brown wrote:
>>> Does this hardware really support anything other than 8 bits per word?
>>> There is no code in the driver which pays any attention to the word
>>> size...
>> the HW has a 128-bit shift register ;-) but driver doesn't look
>> complete.
> That's not the issue - remember that SPI specifies big endian byte
> ordering for words on the bus so things will need to be reordered by the
> hardware for anything except 8 bits.
Yes, I defaulted my driver to assume 8 bits.
I will introduce case by case reads based on t->len

Something like..
case 8:
    readb();
case 16:
    readw();
case 32:
    readl();


~Sourav

  parent reply	other threads:[~2013-07-02 10:26 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-02  8:56 [PATCHv2] drivers: spi: Add qspi flash controller Sourav Poddar
2013-07-02  8:56 ` Sourav Poddar
2013-07-02  8:56 ` Sourav Poddar
2013-07-02  9:24 ` Felipe Balbi
2013-07-02  9:24   ` Felipe Balbi
     [not found]   ` <20130702092458.GI3352-S8G//mZuvNWo5Im9Ml3/Zg@public.gmane.org>
2013-07-02 10:00     ` Sourav Poddar
2013-07-02 10:00       ` Sourav Poddar
2013-07-02 10:00       ` Sourav Poddar
2013-07-02 10:16       ` Felipe Balbi
2013-07-02 10:16         ` Felipe Balbi
     [not found]         ` <20130702101608.GO3352-S8G//mZuvNWo5Im9Ml3/Zg@public.gmane.org>
2013-07-02 10:23           ` Sourav Poddar
2013-07-02 10:23             ` Sourav Poddar
2013-07-02 10:23             ` Sourav Poddar
2013-07-02 10:31             ` Felipe Balbi
2013-07-02 10:31               ` Felipe Balbi
     [not found]               ` <20130702103122.GP3352-S8G//mZuvNWo5Im9Ml3/Zg@public.gmane.org>
2013-07-02 10:39                 ` Sourav Poddar
2013-07-02 10:39                   ` Sourav Poddar
2013-07-02 10:39                   ` Sourav Poddar
2013-07-02  9:32 ` Mark Brown
2013-07-02  9:44   ` Felipe Balbi
2013-07-02  9:44     ` Felipe Balbi
2013-07-02 10:17     ` Mark Brown
     [not found]       ` <20130702101718.GE27646-GFdadSzt00ze9xe1eoZjHA@public.gmane.org>
2013-07-02 10:26         ` Sourav Poddar [this message]
2013-07-02 10:26           ` Sourav Poddar
2013-07-02 10:43       ` Felipe Balbi
2013-07-02 10:43         ` Felipe Balbi
2013-07-02 11:04         ` Mark Brown
2013-07-02 15:19           ` Felipe Balbi
2013-07-02 15:19             ` Felipe Balbi
2013-07-02 15:49             ` Mark Brown
     [not found] ` <1372755399-21769-1-git-send-email-sourav.poddar-l0cyMroinI0@public.gmane.org>
2013-07-02 10:57   ` Sekhar Nori
2013-07-02 10:57     ` Sekhar Nori
     [not found]     ` <51D2B220.1010501-l0cyMroinI0@public.gmane.org>
2013-07-02 10:59       ` Sourav Poddar
2013-07-02 10:59         ` Sourav Poddar
2013-07-02 15:58 ` Felipe Balbi
2013-07-02 15:58   ` Felipe Balbi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=51D2AAF1.4080803@ti.com \
    --to=sourav.poddar-l0cymroini0@public.gmane.org \
    --cc=balbi-l0cyMroinI0@public.gmane.org \
    --cc=broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
    --cc=grant.likely-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org \
    --cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=rnayak-l0cyMroinI0@public.gmane.org \
    --cc=spi-devel-general-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.