Subject: Re: [PATCH] sh_eth: get R8A7740 Rx descriptor word 0 shift out of #ifdef

From: Sergei Shtylyov <[email-masked]>
Date: Tue, 11 Jun 2013 17:01:34 +0400

Hello.

On 11-06-2013 9:34, Shimoda, Yoshihiro wrote:

>> The only R8A7740 specific #ifdef hindering ARM multiplatform  build is left  in
>> sh_eth_rx(): it covers a very strange code shifting Rx buffer descriptor word 0
>> by 16 (which should cause Rx length error to be logged on every buffer  several
>> lines later). Get rid of the #ifdef by adding 'shift_rd0' field to the  'struct
>> sh_eth_cpu_data', making the shift dependent on it, and setting it to 1 for the
>> R8A7740 case...

> This very strange code was from the first R8A7740 supporting patch I sent.
> I should have shifted the RD_RFS values (from RD_RFS1 to RD_RFS10) if R8A7740.
> In other words, since the desc_status also has RDFEND, I should have not shifted
> the desc_status before the driver checked the RDFEND.

> So, I think we have to modify this "desc_status >>= 16" timing.
> Should I submit such a patch first?

    Yes, that would be preferable. Just give it a good description.

> Best regards,
> Yoshihiro Shimoda

WBR, Sergei