From: Andrew Morton <akpm@linux-foundation.org>
To: Alexandre Bounine <alexandre.bounine@idt.com>
Cc: Matt Porter <mporter@kernel.crashing.org>,
Andre van Herk <andre.van.herk@prodrive-technologies.com>,
Barry Wood <barry.wood@idt.com>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH 13/13] rapidio/switches: add driver for IDT gen3 switches
Date: Thu, 21 Jul 2016 11:36:55 -0700 [thread overview]
Message-ID: <20160721113655.bd8e3fd917205d694aac7edd@linux-foundation.org> (raw)
In-Reply-To: <1469125134-16523-14-git-send-email-alexandre.bounine@idt.com>
On Thu, 21 Jul 2016 14:18:54 -0400 Alexandre Bounine <alexandre.bounine@idt.com> wrote:
> Add RapidIO switch driver for IDT Gen3 switch devices: RXS1632 and RXS2448.
>
> ...
>
> +static int
> +idtg3_em_handler(struct rio_dev *rdev, u8 pnum)
> +{
> + u32 err_status;
> + u32 rval;
> +
> + rio_read_config_32(rdev,
> + RIO_DEV_PORT_N_ERR_STS_CSR(rdev, pnum),
> + &err_status);
> +
> + /* Do nothing for device/link removal */
> + if (err_status & RIO_PORT_N_ERR_STS_PORT_UNINIT)
> + return 0;
> +
> + /* When link is OK we have a device insertion.
> + * Request port soft reset to clear errors if they present.
> + * Inbound and outbound ackIDs will be 0 after reset.
> + */
> + if (err_status & (RIO_PORT_N_ERR_STS_OUT_ES |
> + RIO_PORT_N_ERR_STS_INP_ES)) {
> + rio_read_config_32(rdev, RIO_PLM_SPx_IMP_SPEC_CTL(pnum), &rval);
> + rio_write_config_32(rdev, RIO_PLM_SPx_IMP_SPEC_CTL(pnum),
> + rval | RIO_PLM_SPx_IMP_SPEC_CTL_SOFT_RST);
> + udelay(10);
> + rio_write_config_32(rdev, RIO_PLM_SPx_IMP_SPEC_CTL(pnum), rval);
> + mdelay(500);
Yikes, that's a very long busywait. A half-second machine freeze on
uniprocessor (if such exists ;)). We can't use msleep()?
> + }
> +
> + return 0;
> +}
>
> ...
>
next prev parent reply other threads:[~2016-07-21 18:36 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-21 18:18 [PATCH 00/13] RapidIO subsystem updates Alexandre Bounine
2016-07-21 18:18 ` [PATCH 01/13] rapidio: Remove unnecessary 0x prefixes before %pa extension uses Alexandre Bounine
2016-07-21 18:18 ` [PATCH 02/13] rapidio/documentation: fix mangled paragraph in mport_cdev Alexandre Bounine
2016-07-21 18:18 ` [PATCH 03/13] rapidio: fix return value description for dma_prep functions Alexandre Bounine
2016-07-21 18:18 ` [PATCH 04/13] rapidio/tsi721_dma: add channel mask and queue size parameters Alexandre Bounine
2016-07-21 18:18 ` [PATCH 05/13] rapidio/tsi721: add PCIe MRRS override parameter Alexandre Bounine
2016-07-21 18:18 ` [PATCH 06/13] rapidio/tsi721: add messaging mbox selector parameter Alexandre Bounine
2016-07-21 18:18 ` [PATCH 07/13] rapidio/tsi721_dma: advance queue processing from transfer submit call Alexandre Bounine
2016-07-21 18:18 ` [PATCH 08/13] rapidio: fix error handling in mbox request/release functions Alexandre Bounine
2016-07-21 18:18 ` [PATCH 09/13] rapidio/idt_gen2: fix locking warning Alexandre Bounine
2016-07-21 18:18 ` [PATCH 10/13] rapidio: change inbound window size type to u64 Alexandre Bounine
2016-07-21 18:18 ` [PATCH 11/13] rapidio: modify for rev.3 specification changes Alexandre Bounine
2016-07-27 4:53 ` Michael Ellerman
2016-07-27 10:20 ` Wood, Barry
2016-07-27 19:37 ` Andrew Morton
2016-07-28 13:52 ` Michael Ellerman
2016-07-21 18:18 ` [PATCH 12/13] powerpc/fsl_rio: apply changes for RIO spec rev 3 Alexandre Bounine
2016-07-21 18:18 ` [PATCH 13/13] rapidio/switches: add driver for IDT gen3 switches Alexandre Bounine
2016-07-21 18:36 ` Andrew Morton [this message]
2016-07-21 18:48 ` Bounine, Alexandre
2016-07-21 19:01 ` Andrew Morton
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=20160721113655.bd8e3fd917205d694aac7edd@linux-foundation.org \
--to=akpm@linux-foundation.org \
--cc=alexandre.bounine@idt.com \
--cc=andre.van.herk@prodrive-technologies.com \
--cc=barry.wood@idt.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mporter@kernel.crashing.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®