From: Mark Brown <broonie@opensource.wolfsonmicro.com>
To: Girish KS <girishks2000@gmail.com>
Cc: spi-devel-general@lists.sourceforge.net,
linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org, grant.likely@secretlab.ca,
t.figa@samsung.com
Subject: Re: [PATCH V3 2/5] spi: s3c64xx: added support for polling mode
Date: Wed, 3 Apr 2013 12:49:37 +0100 [thread overview]
Message-ID: <20130403114935.GA11305@opensource.wolfsonmicro.com> (raw)
In-Reply-To: <CAKrE-KdWe6aCg0p99BFEeQP-P2nwvdhs2itH3XnHsJMCUjWPAA@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1461 bytes --]
On Wed, Apr 03, 2013 at 05:00:04PM +0530, Girish KS wrote:
> On Mon, Apr 1, 2013 at 6:42 PM, Mark Brown
> >> - if (!sdd->pdev->dev.of_node) {
> >> + if (!sdd->pdev->dev.of_node && !is_polling(sdd)) {
> >> res = platform_get_resource(pdev, IORESOURCE_DMA, 0);
> >> if (!res) {
> >> dev_err(&pdev->dev, "Unable to get SPI tx dma "
> > It seems like it'd be sensible to also handle failure to get the DMA
> > resource by going into polling mode.
> There are 2 cases currently i have identified and handled,
> 1. The SoC's dont have DMA support for spi controller. For such SoC's we
> would not add the dma resource in the spi dts node. In this case the probe
> would return error if failure for DMA resuorce is handled.
That's not what the code currently does...
> 2. The SoC has a DMA support for SPI controller, but due to some x
> reason(H/W bug),
> the driver would force polling mode by enabling
> S3C64XX_SPI_QUIRK_POLL in driver
> data. For such SoC's there would be a dma entry in the spi controller
> dts node, and
> probe can handle failure for DMA resource successfully.
> To handle above both situations successfully if
> (!sdd->pdev->dev.of_node && !is_polling(sdd)) is used.
Right, that's what the code currently does but what I'm suggesting is
that this isn't the most helpful thing to do and that printing a big
warning then soldiering on in polling mode might be more useful.
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
WARNING: multiple messages have this Message-ID (diff)
From: broonie@opensource.wolfsonmicro.com (Mark Brown)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH V3 2/5] spi: s3c64xx: added support for polling mode
Date: Wed, 3 Apr 2013 12:49:37 +0100 [thread overview]
Message-ID: <20130403114935.GA11305@opensource.wolfsonmicro.com> (raw)
In-Reply-To: <CAKrE-KdWe6aCg0p99BFEeQP-P2nwvdhs2itH3XnHsJMCUjWPAA@mail.gmail.com>
On Wed, Apr 03, 2013 at 05:00:04PM +0530, Girish KS wrote:
> On Mon, Apr 1, 2013 at 6:42 PM, Mark Brown
> >> - if (!sdd->pdev->dev.of_node) {
> >> + if (!sdd->pdev->dev.of_node && !is_polling(sdd)) {
> >> res = platform_get_resource(pdev, IORESOURCE_DMA, 0);
> >> if (!res) {
> >> dev_err(&pdev->dev, "Unable to get SPI tx dma "
> > It seems like it'd be sensible to also handle failure to get the DMA
> > resource by going into polling mode.
> There are 2 cases currently i have identified and handled,
> 1. The SoC's dont have DMA support for spi controller. For such SoC's we
> would not add the dma resource in the spi dts node. In this case the probe
> would return error if failure for DMA resuorce is handled.
That's not what the code currently does...
> 2. The SoC has a DMA support for SPI controller, but due to some x
> reason(H/W bug),
> the driver would force polling mode by enabling
> S3C64XX_SPI_QUIRK_POLL in driver
> data. For such SoC's there would be a dma entry in the spi controller
> dts node, and
> probe can handle failure for DMA resource successfully.
> To handle above both situations successfully if
> (!sdd->pdev->dev.of_node && !is_polling(sdd)) is used.
Right, that's what the code currently does but what I'm suggesting is
that this isn't the most helpful thing to do and that printing a big
warning then soldiering on in polling mode might be more useful.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20130403/2f42c448/attachment.sig>
next prev parent reply other threads:[~2013-04-03 11:49 UTC|newest]
Thread overview: 48+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-03-13 6:43 [PATCH V3 0/5] Add polling support for 64xx spi controller Girish K S
2013-03-13 6:43 ` Girish K S
2013-03-13 6:43 ` Girish K S
[not found] ` <1363157014-9615-1-git-send-email-ks.giri-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
2013-03-13 6:43 ` [PATCH V3 1/5] spi: s3c64xx: modified error interrupt handling and init Girish K S
2013-03-13 6:43 ` Girish K S
2013-03-13 6:43 ` Girish K S
2013-04-01 13:03 ` Mark Brown
2013-04-01 13:03 ` Mark Brown
2013-03-13 6:43 ` [PATCH V3 2/5] spi: s3c64xx: added support for polling mode Girish K S
2013-03-13 6:43 ` Girish K S
2013-03-13 6:43 ` Girish K S
2013-04-01 13:12 ` Mark Brown
2013-04-01 13:12 ` Mark Brown
2013-04-03 11:30 ` Girish KS
2013-04-03 11:30 ` Girish KS
2013-04-03 11:49 ` Mark Brown [this message]
2013-04-03 11:49 ` Mark Brown
[not found] ` <20130403114935.GA11305-yzvPICuk2AATkU/dhu1WVueM+bqZidxxQQ4Iyu8u01E@public.gmane.org>
2013-04-04 5:45 ` Girish KS
2013-04-04 5:45 ` Girish KS
2013-04-04 5:45 ` Girish KS
2013-03-13 6:43 ` [PATCH V3 3/5] spi: s3c64xx: Added provision for non-gpio i/o's Girish K S
2013-03-13 6:43 ` Girish K S
2013-03-13 6:43 ` Girish K S
2013-03-13 6:43 ` [PATCH V3 4/5] spi: s3c64xx: Added provision for dedicated cs pin Girish K S
2013-03-13 6:43 ` Girish K S
2013-03-13 6:43 ` Girish K S
2013-04-01 12:57 ` Mark Brown
2013-04-01 12:57 ` Mark Brown
2013-04-08 9:51 ` Girish KS
2013-04-08 9:51 ` Girish KS
2013-04-08 10:15 ` Mark Brown
2013-04-08 10:15 ` Mark Brown
2013-04-08 11:45 ` Girish KS
2013-04-08 11:45 ` Girish KS
2013-04-08 11:52 ` Girish KS
2013-04-08 11:52 ` Girish KS
2013-04-08 12:20 ` Mark Brown
2013-04-08 12:20 ` Mark Brown
2013-04-08 13:49 ` Girish KS
2013-04-08 13:49 ` Girish KS
2013-04-09 10:34 ` Mark Brown
2013-04-09 10:34 ` Mark Brown
2013-03-13 6:43 ` [PATCH V3 5/5] spi: s3c64xx: Added support for exynos5440 spi Girish K S
2013-03-13 6:43 ` Girish K S
2013-03-13 6:43 ` Girish K S
2013-03-25 3:27 ` [PATCH V3 0/5] Add polling support for 64xx spi controller Girish KS
2013-03-25 3:27 ` Girish KS
2013-03-25 3:27 ` Girish KS
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=20130403114935.GA11305@opensource.wolfsonmicro.com \
--to=broonie@opensource.wolfsonmicro.com \
--cc=girishks2000@gmail.com \
--cc=grant.likely@secretlab.ca \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=spi-devel-general@lists.sourceforge.net \
--cc=t.figa@samsung.com \
/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.