Subject: Re: [PATCH v2] Fix SJA1000 command register writes on SMP systems

From: Oliver Hartkopp <[email-masked]>
Date: Tue, 18 May 2010 20:56:18 +0200

On 18.05.2010 07:34, David Miller wrote:
> From: Oliver Hartkopp <[email-masked]>
> Date: Mon, 17 May 2010 22:17:40 +0200
> 
>> diff --git a/drivers/net/can/sja1000/sja1000.c b/drivers/net/can/sja1000/sja1000.c
>> index 145b1a7..2760085 100644
>> --- a/drivers/net/can/sja1000/sja1000.c
>> +++ b/drivers/net/can/sja1000/sja1000.c
>> @@ -84,6 +84,27 @@ static struct can_bittiming_const sja1000_bittiming_const = {
>>  	.brp_inc = 1,
>>  };
>>  +static void sja1000_write_cmdreg(struct sja1000_priv *priv, u8 val)
>> +{
>> +	/* the command register needs some locking on SMP systems */
>> +
>> +#ifdef CONFIG_SMP
> 
> Something is adding spurious leading spaces to lines in your patch.

Sorry. This was probably due to the v2 resend. Will fix.

> Also, please don't SMP conditionalize this code.  It makes it such that
> lock debugging et al. can't be used to check this code on uniprocessor.

Ok.

Will send an updated v3 patch shortly.

Thanks,
Oliver