Bug 120876 - [patch] net/etherboot doesn't compile with gcc4
Summary: [patch] net/etherboot doesn't compile with gcc4
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Doug Ambrisko
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-02-20 11:30 UTC by Jeremie Le Hen
Modified: 2008-03-25 14:10 UTC (History)
1 user (show)

See Also:


Attachments
patch-gcc40-1 (675 bytes, text/plain)
2008-02-20 11:30 UTC, Jeremie Le Hen
no flags Details
patch-gcc40-3 (621 bytes, text/plain)
2008-02-20 11:30 UTC, Jeremie Le Hen
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jeremie Le Hen 2008-02-20 11:30:01 UTC
	GCC 4 is far more nit-picking than its ancestor.

Fix: Drop the following three patchs into the files/ directory.

--- drivers/net/natsemi.c.old	2008-02-20 11:29:11.000000000 +0100
+++ drivers/net/natsemi.c	2008-02-20 11:32:13.000000000 +0100
@@ -602,7 +602,7 @@
 		 const char  *p)     /* Packet */
 {
     u32 to, nstype;
-    u32 tx_status;
+    volatile u32 tx_status;
     
     /* Stop the transmitter */
     outl(TxOff, ioaddr + ChipCmd);
@@ -641,7 +641,7 @@
 
     to = currticks() + TX_TIMEOUT;
 
-    while ((((volatile u32) tx_status=txd.cmdsts) & OWN) && (currticks() < to))
+    while (((tx_status=txd.cmdsts) & OWN) && (currticks() < to))
         /* wait */ ;
 
     if (currticks() >= to) {
--- patch-gcc40-2 ends here ---
How-To-Repeat: 	Simply try to compile net/etherboot on RELENG_7 or CURRENT.
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2008-02-20 11:30:16 UTC
Responsible Changed
From-To: freebsd-ports-bugs->ambrisko

Over to maintainer (via the GNATS Auto Assign Tool)
Comment 2 Doug Ambrisko freebsd_committer freebsd_triage 2008-03-25 14:00:28 UTC
State Changed
From-To: open->closed

Thanks for the patch.  It is applied now.
Comment 3 dfilter service freebsd_committer freebsd_triage 2008-03-25 14:03:42 UTC
ambrisko    2008-03-25 14:03:38 UTC

  FreeBSD ports repository (src committer)

  Added files:
    net/etherboot/files  patch-gcc40 
  Log:
  Make gcc 4 happy.  Thanks for the patch from Jeremie.
  
  PR:             120876
  Submitted by:   Jeremie Le Hen
  
  Revision  Changes    Path
  1.1       +90 -0     ports/net/etherboot/files/patch-gcc40 (new)
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"