All of lore.kernel.org
 help / color / mirror / Atom feed
From: Michael Schmitz <schmitzmic@gmail.com>
To: Finn Thain <fthain@linux-m68k.org>
Cc: linux-m68k@vger.kernel.org, geert@linux-m68k.org, alex@kazik.de,
	netdev@vger.kernel.org
Subject: Re: [PATCH net-next v5 2/2] net/8390: apne.c - add 100 Mbit support to apne.c driver
Date: Sat, 19 Jun 2021 15:13:35 +1200	[thread overview]
Message-ID: <458fe9a3-9a34-d35e-3559-7de498d8f28b@gmail.com> (raw)
In-Reply-To: <83b0640-459c-6f46-e070-1fc9559bd0be@linux-m68k.org>

Hi Finn,

thanks for reviewing again!

Am 19.06.2021 um 12:56 schrieb Finn Thain:
>>
>> +	/* Reset card. Who knows what dain-bramaged state it was left in. */
>> +	{	unsigned long reset_start_time = jiffies;
>
> There's a missing line break here.

Straight copy from apne_probe1() below, but you're right about style of 
course.

>
>> +
>> +		outb(inb(IOBASE + NE_RESET), IOBASE + NE_RESET);
>> +
>> +		while ((inb(IOBASE + NE_EN0_ISR) & ENISR_RESET) == 0)
>> +			if (time_after(jiffies, reset_start_time + 2*HZ/100)) {
>
> You could use msecs_to_jiffies(20) here.
>
>> +				pr_info("Card not found (no reset ack).\n");
>> +				isa_type=ISA_TYPE_AG16;
>
> Whitespace is needed around the '='.
>
>> +			}
>
> Missing a break statement?

Ouch.

>
>> +
>> +		outb(0xff, IOBASE + NE_EN0_ISR);		/* Ack all intr. */
>> +	}
>> +
>>  	dev = alloc_ei_netdev();
>>  	if (!dev)
>>  		return ERR_PTR(-ENOMEM);
>> @@ -590,6 +613,16 @@ static int init_pcmcia(void)
>>  #endif
>>  	u_long offset;
>>
>> +	/* reset card (idea taken from CardReset by Artur Pogoda) */
>> +	if (isa_type == ISA_TYPE_AG16) {
>> +		u_char  tmp = gayle.intreq;
>> +
>
> Extra whitespace.
>
>> +		gayle.intreq = 0xff;
>> +		mdelay(1);
>> +		gayle.intreq = tmp;
>> +		mdelay(300);
>> +	}
>> +
>>  	pcmcia_reset();
>>  	pcmcia_program_voltage(PCMCIA_0V);
>>  	pcmcia_access_speed(PCMCIA_SPEED_250NS);
>>

Thanks, will fix in v6 (and correct the commit message). Might split off 
the autoprobe bit so that can be easily dropped if need be.

Cheers,

	Michael

  reply	other threads:[~2021-06-19  3:13 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-19  0:34 [PATCH v5 0/2] Add APNE PCMCIA 100 Mbit support Michael Schmitz
2021-06-19  0:34 ` [PATCH v5 1/2] m68k: io_mm.h - add APNE 100 MBit support Michael Schmitz
2021-06-19  0:34 ` [PATCH net-next v5 2/2] net/8390: apne.c - add 100 Mbit support to apne.c driver Michael Schmitz
2021-06-19  0:56   ` Finn Thain
2021-06-19  3:13     ` Michael Schmitz [this message]
2021-06-19  9:08   ` Geert Uytterhoeven
2021-06-19 19:31     ` Michael Schmitz
2021-06-20 11:47       ` Geert Uytterhoeven
2021-06-20 19:36         ` Michael Schmitz

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=458fe9a3-9a34-d35e-3559-7de498d8f28b@gmail.com \
    --to=schmitzmic@gmail.com \
    --cc=alex@kazik.de \
    --cc=fthain@linux-m68k.org \
    --cc=geert@linux-m68k.org \
    --cc=linux-m68k@vger.kernel.org \
    --cc=netdev@vger.kernel.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 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.