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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20160721113655.bd8e3fd917205d694aac7edd@linux-foundation.org>
Date:	Thu, 21 Jul 2016 11:36:55 -0700
From:	Andrew Morton <akpm@...ux-foundation.org>
To:	Alexandre Bounine <alexandre.bounine@....com>
Cc:	Matt Porter <mporter@...nel.crashing.org>,
	Andre van Herk <andre.van.herk@...drive-technologies.com>,
	Barry Wood <barry.wood@....com>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 13/13] rapidio/switches: add driver for IDT gen3
 switches

On Thu, 21 Jul 2016 14:18:54 -0400 Alexandre Bounine <alexandre.bounine@....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;
> +}
>
> ...
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ