From: Pavel Machek <pavel@ucw.cz>
To: kernel list <linux-kernel@vger.kernel.org>, jgarzik@pobox.com
Subject: hp100: Detect coax cabling
Date: Tue, 10 Dec 2002 23:01:27 +0100 [thread overview]
Message-ID: <20021210220127.GA544@elf.ucw.cz> (raw)
Hi!
This is only non-trivial patch from this series. It prints coax
vs. 10baseT information to the user, and fixes indentation. Please apply,
Pavel
--- clean/drivers/net/hp100.c 2002-11-23 19:55:22.000000000 +0100
+++ linux-swsusp/drivers/net/hp100.c 2002-12-09 21:19:48.000000000 +0100
@@ -356,8 +353,8 @@
* address - Jean II */
static inline dma_addr_t virt_to_whatever(struct net_device *dev, u32 * ptr)
{
- return ((u_long) ptr) +
- ((struct hp100_private *) (dev->priv))->whatever_offset;
+ return ((u_long) ptr) +
+ ((struct hp100_private *) (dev->priv))->whatever_offset;
}
/* TODO: This function should not really be needed in a good design... */
@@ -854,7 +849,10 @@
printk("100Mb/s Voice Grade AnyLAN network.\n");
break;
case HP100_LAN_10:
- printk("10Mb/s network.\n");
+ printk("10Mb/s network (10baseT).\n");
+ break;
+ case HP100_LAN_COAX:
+ printk("10Mb/s network (coax).\n");
break;
default:
printk("Warning! Link down.\n");
@@ -2535,11 +2534,16 @@
return HP100_LAN_10;
if (val_10 & HP100_AUI_ST) { /* have we BNC or AUI onboard? */
+ /*
+ * This can be overriden by dos utility, so if this has no effect,
+ * perhaps you need to download that utility from HP and set card
+ * back to "auto detect".
+ */
val_10 |= HP100_AUI_SEL | HP100_LOW_TH;
hp100_page(MAC_CTRL);
hp100_outb(val_10, 10_LAN_CFG_1);
hp100_page(PERFORMANCE);
- return HP100_LAN_10;
+ return HP100_LAN_COAX;
}
if ((lp->id->id == 0x02019F022) ||
--- clean/drivers/net/hp100.h 2001-05-16 19:25:38.000000000 +0200
+++ linux-swsusp/drivers/net/hp100.h 2002-11-28 21:18:09.000000000 +0100
@@ -518,12 +518,13 @@
*/
#define HP100_LAN_100 100 /* lan_type value for VG */
#define HP100_LAN_10 10 /* lan_type value for 10BaseT */
+#define HP100_LAN_COAX 9 /* lan_type value for Coax */
#define HP100_LAN_ERR (-1) /* lan_type value for link down */
#define TRUE 1
#define FALSE 0
/*
* Bus Master Data Structures ----------------------------------------------
*/
--
Worst form of spam? Adding advertisment signatures ala sourceforge.net.
What goes next? Inserting advertisment *into* email?
reply other threads:[~2002-12-11 22:33 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20021210220127.GA544@elf.ucw.cz \
--to=pavel@ucw.cz \
--cc=jgarzik@pobox.com \
--cc=linux-kernel@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.