Bug 22176

Summary: if_delmulti() doesn't notify the interface
Product: Base System Reporter: Yar Tikhiy <yar>
Component: kernAssignee: Yar Tikhiy <yar>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: 4.1-STABLE   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
file.diff none

Description Yar Tikhiy 2000-10-21 10:30:01 UTC
	The kernel if_delmulti() function is for removing multicast
	group addresses from an interface. After removing a link-layer
	address, an interface driver must be notified by calling
	its if_ioctl(), so it can rebuild hardware filters etc.

	However, if_delmulti() returns early and fails to notify
	a driver if an AF_LINK address has been removed. That
	happens because such an address usually doesn't have a
	helper ifma->ifma_addr->lladdr address (the pointer is
	null), unlike IP or other higher-level protocol multicasts.
	Noteably, ether_resolvemulti() sets "*llsa" to NULL when
	invoked on an AF_LINK address.

How-To-Repeat: 
	Join an ethernet muticast group from within kernel and then
	leave it using the if_addmulti()/if_delmulti() pair of
	functions. See the interface still recieving the multicasts
	(e.g. with the "tcpdump -p" command)

	I noticed that myself when debugging an ISL VLAN driver.
Comment 1 Yar Tikhiy freebsd_committer freebsd_triage 2001-03-27 14:16:56 UTC
State Changed
From-To: open->analyzed

Fixed in -current
Comment 2 Yar Tikhiy freebsd_committer freebsd_triage 2001-03-27 14:28:41 UTC
Responsible Changed
From-To: freebsd-bugs->yar

Assign the PR to myself since it's me who deals with 
the problem.
Comment 3 Yar Tikhiy freebsd_committer freebsd_triage 2001-03-31 12:12:03 UTC
State Changed
From-To: analyzed->closed

Fixed in both branches