Bug 33833

Summary: Correct kernel config for 4.4-RELEASE is incorrect for 4.5-RC1
Product: Base System Reporter: Eugene Grosbein <ports>
Component: kernAssignee: Remko Lodder <remko>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: Unspecified   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
smime.p7s none

Description Eugene Grosbein 2002-01-13 09:20:00 UTC
	MFC 1.24.2.11 of src/sys/netinet/ip_dummynet.c made
	ipfw/dummynet/bridge KLD'able and broke compilations of kernels
	containing DUMMYNET and not containing pseudo-device ether.

Fix: 

Workaround: add pseudo-device ether to kernel config
	even if you do not need this.

	Fix: unknown for me. If this won't be fixed before release, 
	this should be documented in the src/UPDATING and dummynet(4)
	man page.
	
	pseudo-device ether adds currently 16Kb to kernel size.

Eugene Grosbein
How-To-Repeat: 	
	Try to build this kernel. 
	It's nearly real config for PPP-only networking.

#start of file
machine		i386
cpu		I486_CPU
cpu		I586_CPU
cpu		I686_CPU
ident		EP
maxusers	4

options		INET			#InterNETworking
options		FFS			#Berkeley Fast Filesystem
options		FFS_ROOT		#FFS usable as root device [keep this!]
options		COMPAT_43		#Compatible with BSD 4.3 [KEEP THIS!]
options		USERCONFIG		#boot -c editor
options		VISUAL_USERCONFIG	#visual boot -c editor
options		IPFIREWALL
options		IPFIREWALL_FORWARD
options		IPDIVERT
options		DUMMYNET

device	isa0

device	fdc0	at isa? port IO_FD1 irq 6 drq 2
device		fd0	at fdc0 drive 0
#device		fd1	at fdc0 drive 1

device	ata0	at isa? port IO_WD1 irq 14
device	ata
device	atadisk

options ATA_STATIC_ID

device		atkbdc0	at isa? port IO_KBD flags 0x01
device		atkbd0	at atkbdc? irq 1
device		vga0	at isa? port ?
options		VGA_NO_MODE_CHANGE
device		sc0	at isa?
options		SC_NO_CUTPASTE
options		SC_NO_SYSMOUSE
options		MAXCONS=8
device		npx0	at nexus? port IO_NPX irq 13

device		sio0	at isa? port IO_COM1 flags 0x10 irq 4
device		sio1	at isa? port IO_COM2 irq 3
device		sio2	at isa? port IO_COM3 irq 7
device		sio3	at isa? port IO_COM4 irq 5

pseudo-device	loop
pseudo-device	ppp 	3
pseudo-device	pty
pseudo-device	bpf	#required by PPP_FILTER
pseudo-device	snp	4
pseudo-device   gif
 
options		PPP_DEFLATE
options		PPP_BSDCOMP
options		PPP_FILTER
options		TCP_DROP_SYNFIN
options		ICMP_BANDLIM
options		DUMMYNET
options		INCLUDE_CONFIG_FILE
options		HZ=1000
options		P1003_1B
options		_KPOSIX_PRIORITY_SCHEDULING
options		_KPOSIX_VERSION=199309L
options		CLK_CALIBRATION_LOOP
options		CLK_USE_I8254_CALIBRATION
options		RANDOM_IP_ID
#end if file

	There are last lines of make's output.

cc -c -O -pipe -march=pentiumpro -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes  -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual  -fformat-extensions -ansi  -nostdinc -I- -I. -I../.. -I../../../include -I../../contrib/ipfilter  -D_KERNEL -include opt_global.h -elf  -mpreferred-stack-boundary=2 setdef1.c
touch hack.c
cc -elf -shared -nostdlib hack.c -o hack.So
rm -f hack.c
sh ../../conf/newvers.sh EP
cc -c -O -pipe -march=pentiumpro -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes  -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual  -fformat-extensions -ansi  -nostdinc -I- -I. -I../.. -I../../../include -I../../contrib/ipfilter  -D_KERNEL -include opt_global.h -elf  -mpreferred-stack-boundary=2 vers.c
linking kernel
ip_dummynet.o: In function `transmit_event':
ip_dummynet.o(.text+0x44e): undefined reference to `bdgtakeifaces_ptr'
ip_dummynet.o(.text+0x4ae): undefined reference to `bdg_forward_ptr'
*** Error code 1
Comment 1 Eugene Grosbein 2003-02-04 10:07:07 UTC
Hi!

The problem is still here at the time of 4.7-STABLE:
dummynet(4) still does not note in 'KERNEL OPTION' section
that 'pseudo-device ether' is mandatory for dummynet
even for PPP-only operations.

Eugene Grosbein
Comment 2 Maxim Konovalov freebsd_committer freebsd_triage 2003-02-04 10:16:13 UTC
On 17:07+0700, Feb 4, 2003, Eugene Grosbein wrote:

> Hi!
>
> The problem is still here at the time of 4.7-STABLE:
> dummynet(4) still does not note in 'KERNEL OPTION' section
> that 'pseudo-device ether' is mandatory for dummynet
> even for PPP-only operations.
>
> Eugene Grosbein

I believe it is a bug in dummynet code. See a related PR, kern/37261.

-- 
Maxim Konovalov, maxim@macomnet.ru, maxim@FreeBSD.org
Comment 3 Eugene Grosbein 2003-05-13 05:29:52 UTC
Are there any plans to deal with this PR and related
http://www.FreeBSD.org/cgi/query-pr.cgi?pr=kern/37261 ?

Eugene Grosbein
Comment 4 ru freebsd_committer freebsd_triage 2003-05-14 17:32:50 UTC
On Tue, May 13, 2003 at 12:29:52PM +0800, Eugene Grosbein wrote:
> Are there any plans to deal with this PR and related
> http://www.FreeBSD.org/cgi/query-pr.cgi?pr=kern/37261 ?
> 

Eugene,

I'm not going to commit any patches to fix this.  I've
once developed a patch for 4.x, it's now up to Luigi to
commit it or not.


Cheers,
-- 
Ruslan Ermilov		Sysadmin and DBA,
ru@sunbay.com		Sunbay Software AG,
ru@FreeBSD.org		FreeBSD committer,
+380.652.512.251	Simferopol, Ukraine

http://www.FreeBSD.org	The Power To Serve
http://www.oracle.com	Enabling The Information Age
Comment 5 Eugene Grosbein 2003-05-15 03:30:32 UTC
Ruslan Ermilov wrote:
> 
> On Tue, May 13, 2003 at 12:29:52PM +0800, Eugene Grosbein wrote:
> > Are there any plans to deal with this PR and related
> > http://www.FreeBSD.org/cgi/query-pr.cgi?pr=kern/37261 ?
> >
> Eugene,
> 
> I'm not going to commit any patches to fix this.  I've
> once developed a patch for 4.x, it's now up to Luigi to
> commit it or not.

Well, could you please give your patch to me for testing?

Eugene Grosbein
Comment 6 ru freebsd_committer freebsd_triage 2003-05-15 07:24:16 UTC
On Thu, May 15, 2003 at 10:30:32AM +0800, Eugene Grosbein wrote:
> Ruslan Ermilov wrote:
> > 
> > On Tue, May 13, 2003 at 12:29:52PM +0800, Eugene Grosbein wrote:
> > > Are there any plans to deal with this PR and related
> > > http://www.FreeBSD.org/cgi/query-pr.cgi?pr=kern/37261 ?
> > >
> > Eugene,
> > 
> > I'm not going to commit any patches to fix this.  I've
> > once developed a patch for 4.x, it's now up to Luigi to
> > commit it or not.
> 
> Well, could you please give your patch to me for testing?
> 

It should be somewhere in this PR's Audit-Trail I suppose,
if I recall the things correctly.


Cheers,
-- 
Ruslan Ermilov		Sysadmin and DBA,
ru@sunbay.com		Sunbay Software AG,
ru@FreeBSD.org		FreeBSD committer,
+380.652.512.251	Simferopol, Ukraine

http://www.FreeBSD.org	The Power To Serve
http://www.oracle.com	Enabling The Information Age
Comment 7 Kris Kennaway freebsd_committer freebsd_triage 2003-07-14 11:21:44 UTC
Responsible Changed
From-To: freebsd-bugs->luigi

Assign to ipfw maintainer
Comment 8 Daniel Gerzo 2005-02-22 03:18:24 UTC
Hi freebsd-gnats-submit,

  this seems to be really outdated and could be closed, couldn't it ?

-- 
Best regards

+----------==/\/\==----------+             FreeBSD
| DanGer <danger@wilbury.sk> |     (__)    The
| DanGer@IRCnet ICQ261701668 |  \\\'',)    Power
| http://danger.homeunix.org |    \/  \ ^  To
+----------==\/\/==----------+    .\._/_)  Serve

[ Wacky Wheels รพ Put it in reverse and run over Mario Kart! ]
Comment 9 Eugene Grosbein 2005-02-23 12:02:01 UTC
DanGer wrote:

> this seems to be really outdated and could be closed, couldn't it ?

Does it mean the problem is fixed?

Eugene Grosbein
Comment 10 Eugene Grosbein 2006-01-07 09:44:41 UTC
The problem is still here for 6.0-RELEASE.
dummynet(4) still does not mention that options DUMMYNET
requires device ether.

Here is kernel config adopted for 6.0-RELEASE.
The kernel can be configured, compiled but not linked:

linking kernel
if.o(.text+0x29a9): In function `if_setlladdr':
: undefined reference to `arp_ifinit'
ip_dummynet.o(.text+0x509): In function `transmit_event':
: undefined reference to `bridge_dn_p'
ip_dummynet.o(.text+0x52e): In function `transmit_event':
: undefined reference to `ether_output_frame'
ip_dummynet.o(.text+0x563): In function `transmit_event':
: undefined reference to `ether_demux'
ip_dummynet.o(.text+0x56d): In function `transmit_event':
: undefined reference to `bdgtakeifaces_ptr'
ip_dummynet.o(.text+0x58f): In function `transmit_event':
: undefined reference to `bdg_forward_ptr'
*** Error code 1

Stop in /mnt/usr/local/obj6/usr/src/sys/EP.
*** Error code 1

Stop in /usr/src.
*** Error code 1

Stop in /usr/src.

Kernel config file follows:

#start of file
machine		i386
cpu		I486_CPU
cpu		I586_CPU
cpu		I686_CPU
ident		EP
maxusers	4

options		SCHED_4BSD
options		INET			#InterNETworking
options		FFS			#Berkeley Fast Filesystem
options		COMPAT_43		#Compatible with BSD 4.3 [KEEP THIS!]
options		IPFIREWALL
options		IPFIREWALL_FORWARD
options		IPDIVERT
options		DUMMYNET

device	isa
device	fdc
device	ata
device	atadisk

options ATA_STATIC_ID

device		atkbdc
device		atkbd
device		vga
options		VGA_NO_MODE_CHANGE
device		sc
options		SC_NO_CUTPASTE
options		SC_NO_SYSMOUSE
options		MAXCONS=8
device		npx

device		sio

device	loop
device	ppp
device	pty
device	bpf	#required by PPP_FILTER
device	snp
device  gif

options		PPP_DEFLATE
options		PPP_BSDCOMP
options		PPP_FILTER
options		TCP_DROP_SYNFIN
options		DUMMYNET
options		INCLUDE_CONFIG_FILE
options		HZ=1000
options		_KPOSIX_PRIORITY_SCHEDULING
options		CLK_CALIBRATION_LOOP
options		CLK_USE_I8254_CALIBRATION
#end if file

Eugene Grosbein
Comment 11 Remko Lodder freebsd_committer freebsd_triage 2006-12-31 11:04:18 UTC
State Changed
From-To: open->feedback

Hello, so the problem is still current on a 6.0 machine, 
if you look through the GENERIC kernel configuation you 
will notice this line: 

device          ether           # Ethernet support 

Which basically tells : If you are doing anything that 
requires ethernetworking, you should include this. 

Now the following question would be ofcourse: Do you use 
any ethernetworking ? I think you do (i think almost 
everyone uses this): but i am not very sure about the 
definition of ethernet support here. 


Comment 12 Remko Lodder freebsd_committer freebsd_triage 2006-12-31 11:04:18 UTC
Responsible Changed
From-To: luigi->remko

grab the pr to discuss this with the submitter to see whether the 
current kernel option is sufficient.
Comment 13 Remko Lodder freebsd_committer freebsd_triage 2007-01-05 12:16:07 UTC
State Changed
From-To: feedback->closed

We cannot get the proper feedback, the submitters address bounces. If 
somone has feedback, please notify me.