mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Mikael Pettersson <mikpe@csd.uu.se>
To: laughing@shared-source.org, linux-kernel@vger.kernel.org
Subject: Re: Linux 2.4.6-ac4
Date: Mon, 16 Jul 2001 13:58:49 +0200 (MET DST)	[thread overview]
Message-ID: <200107161158.NAA09324@harpo.it.uu.se> (raw)

Alan,

Compiling 2.4.6-ac4 (x86, CONFIG_PCI) I get:

gcc -D__KERNEL__ -I/tmp/linux-2.4.6-ac4/include -Wall -Wstrict-prototypes -Wno-trigraphs -O2 -fomit-frame-pointer -fno-strict-aliasing -fno-common -pipe -mpreferred-stack-boundary=2 -march=i686    -c -o quirks.o quirks.c
quirks.c:112: warning: `/*' within comment
quirks.c: In function `quirk_vialatency':
quirks.c:145: warning: passing arg 3 of `pci_write_config_byte' makes integer from pointer without a cast
...
gcc -D__KERNEL__ -I/tmp/linux-2.4.6-ac4/include -Wall -Wstrict-prototypes -Wno-trigraphs -O2 -fomit-frame-pointer -fno-strict-aliasing -fno-common -pipe -mpreferred-stack-boundary=2 -march=i686    -c -o bluesmoke.o bluesmoke.c
bluesmoke.c:241: warning: initialization from incompatible pointer type

Of these three warnings, the second (drivers/pci/quirks.c:pci_write_config_byte)
indicates a real bug (passing a pointer to int instead of the int itself).
The patch below fixes this bug and silences the other two warnings.

/Mikael


--- linux-2.4.6-ac4/arch/i386/kernel/bluesmoke.c.~1~	Mon Jul 16 13:10:04 2001
+++ linux-2.4.6-ac4/arch/i386/kernel/bluesmoke.c	Mon Jul 16 13:25:01 2001
@@ -233,7 +233,7 @@
 	}
 }
 
-static int __init mcheck_disable(char *str, int *unused)
+static int __init mcheck_disable(char *str)
 {
 	mce_disabled = 1;
 	return 0;
--- linux-2.4.6-ac4/drivers/pci/quirks.c.~1~	Mon Jul 16 13:10:06 2001
+++ linux-2.4.6-ac4/drivers/pci/quirks.c	Mon Jul 16 13:21:40 2001
@@ -108,7 +108,7 @@
 	if(p!=NULL)
 	{
 		pci_read_config_byte(p, PCI_CLASS_REVISION, &rev);
-		/* 0x40 - 0x4f == 686B, 0x10 - 0x2f == 686A; thanks Dan Hollis
+		/* 0x40 - 0x4f == 686B, 0x10 - 0x2f == 686A; thanks Dan Hollis */
 		/* Check for buggy part revisions */
 		if (rev < 0x40 && rev > 0x42) 
 			return;
@@ -142,7 +142,7 @@
 	   "Master priority rotation on every PCI master grant */
 	busarb &= ~(1<<5);
 	busarb |= (1<<4);
-	pci_write_config_byte(dev, 0x76, &busarb);
+	pci_write_config_byte(dev, 0x76, busarb);
 	printk(KERN_INFO "Applying VIA southbridge workaround.\n");
 }
 

             reply	other threads:[~2001-07-16 11:59 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-07-16 11:58 Mikael Pettersson [this message]
2001-07-16 12:24 ` Xavier Bestel
2001-07-16 12:45 ` Alan Cox
2001-07-16 16:18 ` Xavier Bestel
  -- strict thread matches above, loose matches on Subject: below --
2001-07-15 23:49 Alan Cox
2001-07-16  0:20 ` David Ford
2001-07-16  0:49 ` David S. Miller
2001-07-16  2:02 ` Udo A. Steinberg
2001-07-16  2:13   ` Udo A. Steinberg
2001-07-16 11:16     ` Alan Cox

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=200107161158.NAA09324@harpo.it.uu.se \
    --to=mikpe@csd.uu.se \
    --cc=laughing@shared-source.org \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®