From: Jeff Garzik <jgarzik@mandrakesoft.com>
To: Matthew Wilcox <willy@debian.org>
Cc: Linus Torvalds <torvalds@transmeta.com>, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] compile fix for dl2k
Date: Sun, 04 Aug 2002 13:32:23 -0400 [thread overview]
Message-ID: <3D4D6527.8080405@mandrakesoft.com> (raw)
In-Reply-To: 20020804170747.M24631@parcelfarce.linux.theplanet.co.uk
Matthew Wilcox wrote:
> synchronise_irq now takes an argument.
> it was using set_bit / test_bit inappropriately.
>
> diff -urpNX dontdiff linux-2.5.30/drivers/net/dl2k.c linux-2.5.30-willy/drivers/net/dl2k.c
> --- linux-2.5.30/drivers/net/dl2k.c 2002-06-20 16:53:51.000000000 -0600
> +++ linux-2.5.30-willy/drivers/net/dl2k.c 2002-08-04 08:23:47.000000000 -0600
> @@ -1108,7 +1108,6 @@ set_multicast (struct net_device *dev)
> u16 rx_mode = 0;
> int i;
> int bit;
> - int index, crc;
> struct dev_mc_list *mclist;
> struct netdev_private *np = dev->priv;
>
> @@ -1130,13 +1129,14 @@ set_multicast (struct net_device *dev)
> for (i=0, mclist = dev->mc_list; mclist && i < dev->mc_count;
> i++, mclist=mclist->next) {
>
> - crc = ether_crc_le (ETH_ALEN, mclist->dmi_addr);
> + int index = 0;
> + int crc = ether_crc_le (ETH_ALEN, mclist->dmi_addr);
>
> /* The inverted high significant 6 bits of CRC are
> used as an index to hashtable */
> - for (index = 0, bit = 0; bit < 6; bit++)
> - if (test_bit(31 - bit, &crc))
> - set_bit(bit, &index);
> + for (bit = 0; bit < 6; bit++)
> + if (crc & (1 << (31 - bit)))
> + index |= (1 << bit);
>
> hash_table[index / 32] |= (1 << (index % 32));
> }
patch applied
> @@ -1635,7 +1635,7 @@ rio_close (struct net_device *dev)
>
> /* Stop Tx and Rx logics */
> writel (TxDisable | RxDisable | StatsDisable, ioaddr + MACCtrl);
> - synchronize_irq ();
> + synchronize_irq (dev->irq);
> free_irq (dev->irq, dev);
> del_timer_sync (&np->timer);
patch already applied, dropping hunk
Jeff
prev parent reply other threads:[~2002-08-04 17:28 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-08-04 16:07 [PATCH] compile fix for dl2k Matthew Wilcox
2002-08-04 17:32 ` Jeff Garzik [this message]
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=3D4D6527.8080405@mandrakesoft.com \
--to=jgarzik@mandrakesoft.com \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@transmeta.com \
--cc=willy@debian.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.