#20930: Linux compilation failure
-------------------------+------------------------
  Reporter:  spk.punith  |      Owner:  developers
      Type:  defect      |     Status:  new
  Priority:  high        |  Milestone:
 Component:  kernel      |    Version:  Trunk
Resolution:              |   Keywords:
-------------------------+------------------------

Comment (by anonymous):

 The reporter is telling about the issue wrt generic-patch
 911-kobject_add_broadcast_uevent.patch.

 In this patch

 --- a/include/linux/kobject.h
 +++ b/include/linux/kobject.h
 @@ -31,6 +31,8 @@
  #define UEVENT_NUM_ENVP      32  /* number of env pointers */
  #define UEVENT_BUFFER_SIZE   2048  /* buffer for the variables */

 +struct sk_buff;/* This should be protected under the macro CONFIG_NET*/
 +
  /* path to the userspace helper executed on an event */
  extern char uevent_helper[];

 @@ -213,4 +215,7 @@ int add_uevent_var(struct kobj_uevent_en
  int kobject_action_type(const char *buf, size_t count,
       enum kobject_action *type);
 /*: This also should be protected under the macro CONFIG_NET, because
 skbuff is not defined when CONFIG_NET is not enabled*/

 +int broadcast_uevent(struct sk_buff *skb, __u32 pid, __u32 group,
 +        gfp_t allocation);
 +
  #endif /* _KOBJECT_H_ */




 --- a/lib/kobject_uevent.c
 +++ b/lib/kobject_uevent.c
 @@ -382,6 +382,43 @@ int add_uevent_var(struct kobj_uevent_en
  EXPORT_SYMBOL_GPL(add_uevent_var);

  #if defined(CONFIG_NET)
 +int broadcast_uevent(struct sk_buff *skb, __u32 pid, __u32 group,
 +        gfp_t allocation)
 +{
 ....................
 ....................
 ....................
 }
 #else
 +int broadcast_uevent(struct sk_buff *skb, __u32 pid, __u32 group,
 +        gfp_t allocation)
 +{
 + kfree_skb(skb);
 + return 0;
 +}
 +#endif
 +EXPORT_SYMBOL_GPL(broadcast_uevent);

 should be modified to

  #if defined(CONFIG_NET)
 +int broadcast_uevent(struct sk_buff *skb, __u32 pid, __u32 group,
 +        gfp_t allocation)
 +{
 ....................
 ....................
 ....................
 }
 +EXPORT_SYMBOL_GPL(broadcast_uevent);
 +#endif

 as there shouldn't be any #else condition when CONFIG_NET is not defined

--
Ticket URL: <https://dev.openwrt.org/ticket/20930#comment:2>
OpenWrt <http://openwrt.org>
Opensource Wireless Router Technology
_______________________________________________
openwrt-tickets mailing list
[email protected]
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-tickets

Reply via email to