Re: [PATCH 1/3] [net/core] move dev_mc_discard from dev_mcast.c to dev.c



From: Denis Cheng <crquan@xxxxxxxxx>
Date: Wed, 18 Jul 2007 10:41:03 +0800

Because this function is only called by unregister_netdevice,
this moving could make this non-global function static,
and also remove its declaration in netdevice.h;

Any further, function __dev_addr_discard is also just called by
dev_mc_discard and dev_unicast_discard, keeping this two functions
both in one c file could make __dev_addr_discard also static
and remove its declaration in netdevice.h;

Futhermore, the sequential call to dev_unicast_discard and then
dev_mc_discard in unregister_netdevice have a similar mechanism that:
(netif_tx_lock_bh / __dev_addr_discard / netif_tx_unlock_bh),
they should merged into one to eliminate duplicates in acquiring and
releasing the dev->_xmit_lock, this would be done in my following patch.

Signed-off-by: Denis Cheng <crquan@xxxxxxxxx>

Patch applied, thanks.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



Relevant Pages

  • Re: [PATCH 1/3] [net/core] move dev_mc_discard from dev_mcast.c to dev.c
    ... On 7/18/07, David Miller wrote: ... > this moving could make this non-global function static, ... > and also remove its declaration in netdevice.h; ... I don't think the single file dev_mcast.c is needed anymore. ...
    (Linux-Kernel)
  • Re: operator inheritance problem
    ... > I modified the derived class this way: ... Note that compiler implementation of using declarations are very buggy, ... After moving the using declaration to after public:, ...
    (comp.lang.cpp)
  • RE: [PATCH] [IA64] Include kexec.h in arch/ia64/kernel/process.c
    ... declaration of kexec_disable_iosapicwhich is used in machine_shutdown. ... I merged this into your earlier change (moving machine_shutdown() into ... inside kexec.h for the #ifndef CONFIG_KEXEC case? ... More majordomo info at http://vger.kernel.org/majordomo-info.html ...
    (Linux-Kernel)
  • Re: Format and CString question
    ... > My gut feeling would be that moving the declaration was hiding the real ...
    (microsoft.public.vc.mfc)
  • Re: [PATCH] (-mm) drivers/pci/msi: explicit declaration of msi_register
    ... We don't want to add a duplicated declaration like this. ... resides outside of drivers/pci can use the declaration without having to ... for platform-specific code. ... I am not against moving sn/pci/msi.c into drivers if that is ...
    (Linux-Kernel)