backports: Add NFC patches
PATCH 1/1 backports: Add NFC patches
These are NFC patches refreshed on next-20130328
Signed-off-by Thierry Escande <[email protected]>
--- .../0005-netlink-portid/net_nfc_netlink.patch | 71 ++++++++++++++++++++ .../network/53-pr_fmt/net_nfc_core.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_hci_command.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_hci_core.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_hci_hcp.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_hci_llc_shdlc.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_llcp_commands.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_llcp_llcp.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_llcp_sock.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_nci_core.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_nci_data.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_nci_ntf.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_nci_rsp.patch | 12 ++++ .../network/53-pr_fmt/net_nfc_netlink.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_rawsock.patch | 13 ++++ .../network/74-driver-core-constify-data/INFO | 7 ++ .../net_nfc_core.patch | 14 ++++ .../network/75-module-alias-genl-family/INFO | 7 ++ .../75-module-alias-genl-family/net_nfc_core.patch | 12 ++++ .../network/76-module-i2c-driver/INFO | 7 ++ .../drivers_nfc_microread_i2c.patch | 14 ++++ .../drivers_nfc_pn544_i2c.patch | 14 ++++ 22 files changed, 327 insertions(+) create mode 100644 patches/collateral-evolutions/network/0005-netlink-portid/net_nfc_netlink.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_core.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_hci_command.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_hci_core.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_hci_hcp.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_hci_llc_shdlc.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_llcp_commands.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_llcp_llcp.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_llcp_sock.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_nci_core.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_nci_data.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_nci_ntf.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_nci_rsp.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_netlink.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_rawsock.patch create mode 100644 patches/collateral-evolutions/network/74-driver-core-constify-data/INFO create mode 100644 patches/collateral-evolutions/network/74-driver-core-constify-data/net_nfc_core.patch create mode 100644 patches/collateral-evolutions/network/75-module-alias-genl-family/INFO create mode 100644 patches/collateral-evolutions/network/75-module-alias-genl-family/net_nfc_core.patch create mode 100644 patches/collateral-evolutions/network/76-module-i2c-driver/INFO create mode 100644 patches/collateral-evolutions/network/76-module-i2c-driver/drivers_nfc_microread_i2c.patch create mode 100644 patches/collateral-evolutions/network/76-module-i2c-driver/drivers_nfc_pn544_i2c.patch
patches/collateral-evolutions/network/0005-netlink-portid/net_nfc_netlink.patch new file +71 -0
@@ -0,0 +1,71 @@ +--- a/net/nfc/netlink.c ++++ b/net/nfc/netlink.c +@@ -69,7 +69,7 @@ static int nfc_genl_send_target(struct s + { + void *hdr; + +- hdr = genlmsg_put(msg, NETLINK_CB(cb->skb).portid, cb->nlh->nlmsg_seq, ++ hdr = genlmsg_put(msg, NETLINK_CB_PORTID(cb->skb), cb->nlh->nlmsg_seq, + &nfc_genl_family, flags, NFC_CMD_GET_TARGET); + if (!hdr) + return -EMSGSIZE; +@@ -482,7 +482,7 @@ static int nfc_genl_dump_devices(struct + while (dev) { + int rc; + +- rc = nfc_genl_send_device(skb, dev, NETLINK_CB(cb->skb).portid, ++ rc = nfc_genl_send_device(skb, dev, NETLINK_CB_PORTID(cb->skb), + cb->nlh->nlmsg_seq, cb, NLM_F_MULTI); + if (rc < 0) + break; +@@ -601,7 +601,7 @@ static int nfc_genl_get_device(struct sk + goto out_putdev; + } + +- rc = nfc_genl_send_device(msg, dev, info->snd_portid, info->snd_seq, ++ rc = nfc_genl_send_device(msg, dev, genl_info_snd_portid(info), info->snd_seq, + NULL, 0); + if (rc < 0) + goto out_free; +@@ -692,7 +692,7 @@ static int nfc_genl_start_poll(struct sk + + rc = nfc_start_poll(dev, im_protocols, tm_protocols); + if (!rc) +- dev->genl_data.poll_req_portid = info->snd_portid; ++ dev->genl_data.poll_req_portid = genl_info_snd_portid(info); + + mutex_unlock(&dev->genl_data.genl_data_mutex); + +@@ -726,7 +726,7 @@ static int nfc_genl_stop_poll(struct sk_ + + mutex_lock(&dev->genl_data.genl_data_mutex); + +- if (dev->genl_data.poll_req_portid != info->snd_portid) { ++ if (dev->genl_data.poll_req_portid != genl_info_snd_portid(info)) { + rc = -EBUSY; + goto out; + } +@@ -852,7 +852,7 @@ static int nfc_genl_llc_get_params(struc + goto exit; + } + +- rc = nfc_genl_send_params(msg, local, info->snd_portid, info->snd_seq); ++ rc = nfc_genl_send_params(msg, local, genl_info_snd_portid(info), info->snd_seq); + + exit: + device_unlock(&dev->dev); +@@ -1135,12 +1135,12 @@ static int nfc_genl_rcv_nl_event(struct + if (event != NETLINK_URELEASE || n->protocol != NETLINK_GENERIC) + goto out; + +- pr_debug("NETLINK_URELEASE event from id %d\n", n->portid); ++ pr_debug("NETLINK_URELEASE event from id %d\n", netlink_notify_portid(n)); + + w = kmalloc(sizeof(*w), GFP_ATOMIC); + if (w) { + INIT_WORK((struct work_struct *) w, nfc_urelease_event_work); +- w->portid = n->portid; ++ w->portid = netlink_notify_portid(n); + schedule_work((struct work_struct *) w); + } +
patches/collateral-evolutions/network/53-pr_fmt/net_nfc_core.patch new file +13 -0
@@ -0,0 +1,13 @@ +--- a/net/nfc/core.c ++++ b/net/nfc/core.c +@@ -21,8 +21,10 @@ + * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + */ + ++#undef pr_fmt + #define pr_fmt(fmt) KBUILD_MODNAME ": %s: " fmt, __func__ + ++#include <linux/printk.h> + #include <linux/init.h> + #include <linux/kernel.h> + #include <linux/module.h>
patches/collateral-evolutions/network/53-pr_fmt/net_nfc_hci_command.patch new file +13 -0
@@ -0,0 +1,13 @@ +--- a/net/nfc/hci/command.c ++++ b/net/nfc/hci/command.c +@@ -17,8 +17,10 @@ + * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + */ + ++#undef pr_fmt + #define pr_fmt(fmt) "hci: %s: " fmt, __func__ + ++#include <linux/printk.h> + #include <linux/init.h> + #include <linux/kernel.h> + #include <linux/sched.h>
patches/collateral-evolutions/network/53-pr_fmt/net_nfc_hci_core.patch new file +13 -0
@@ -0,0 +1,13 @@ +--- a/net/nfc/hci/core.c ++++ b/net/nfc/hci/core.c +@@ -17,8 +17,10 @@ + * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + */ + ++#undef pr_fmt + #define pr_fmt(fmt) "hci: %s: " fmt, __func__ + ++#include <linux/printk.h> + #include <linux/init.h> + #include <linux/kernel.h> + #include <linux/module.h>
patches/collateral-evolutions/network/53-pr_fmt/net_nfc_hci_hcp.patch new file +13 -0
@@ -0,0 +1,13 @@ +--- a/net/nfc/hci/hcp.c ++++ b/net/nfc/hci/hcp.c +@@ -17,8 +17,10 @@ + * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + */ + ++#undef pr_fmt + #define pr_fmt(fmt) "hci: %s: " fmt, __func__ + ++#include <linux/printk.h> + #include <linux/init.h> + #include <linux/kernel.h> + #include <linux/module.h>
patches/collateral-evolutions/network/53-pr_fmt/net_nfc_hci_llc_shdlc.patch new file +13 -0
@@ -0,0 +1,13 @@ +--- a/net/nfc/hci/llc_shdlc.c ++++ b/net/nfc/hci/llc_shdlc.c +@@ -18,8 +18,10 @@ + * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + */ + ++#undef pr_fmt + #define pr_fmt(fmt) "shdlc: %s: " fmt, __func__ + ++#include <linux/printk.h> + #include <linux/types.h> + #include <linux/sched.h> + #include <linux/wait.h>
patches/collateral-evolutions/network/53-pr_fmt/net_nfc_llcp_commands.patch new file +13 -0
@@ -0,0 +1,13 @@ +--- a/net/nfc/llcp/commands.c ++++ b/net/nfc/llcp/commands.c +@@ -17,8 +17,10 @@ + * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + */ + ++#undef pr_fmt + #define pr_fmt(fmt) "llcp: %s: " fmt, __func__ + ++#include <linux/printk.h> + #include <linux/init.h> + #include <linux/kernel.h> + #include <linux/module.h>
patches/collateral-evolutions/network/53-pr_fmt/net_nfc_llcp_llcp.patch new file +13 -0
@@ -0,0 +1,13 @@ +--- a/net/nfc/llcp/llcp.c ++++ b/net/nfc/llcp/llcp.c +@@ -17,8 +17,10 @@ + * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + */ + ++#undef pr_fmt + #define pr_fmt(fmt) "llcp: %s: " fmt, __func__ + ++#include <linux/printk.h> + #include <linux/init.h> + #include <linux/kernel.h> + #include <linux/list.h>
patches/collateral-evolutions/network/53-pr_fmt/net_nfc_llcp_sock.patch new file +13 -0
@@ -0,0 +1,13 @@ +--- a/net/nfc/llcp/sock.c ++++ b/net/nfc/llcp/sock.c +@@ -17,8 +17,10 @@ + * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + */ + ++#undef pr_fmt + #define pr_fmt(fmt) "llcp: %s: " fmt, __func__ + ++#include <linux/printk.h> + #include <linux/init.h> + #include <linux/kernel.h> + #include <linux/module.h>
patches/collateral-evolutions/network/53-pr_fmt/net_nfc_nci_core.patch new file +13 -0
@@ -0,0 +1,13 @@ +--- a/net/nfc/nci/core.c ++++ b/net/nfc/nci/core.c +@@ -25,8 +25,10 @@ + * + */ + ++#undef pr_fmt + #define pr_fmt(fmt) KBUILD_MODNAME ": %s: " fmt, __func__ + ++#include <linux/printk.h> + #include <linux/module.h> + #include <linux/types.h> + #include <linux/workqueue.h>
patches/collateral-evolutions/network/53-pr_fmt/net_nfc_nci_data.patch new file +13 -0
@@ -0,0 +1,13 @@ +--- a/net/nfc/nci/data.c ++++ b/net/nfc/nci/data.c +@@ -21,8 +21,10 @@ + * + */ + ++#undef pr_fmt + #define pr_fmt(fmt) KBUILD_MODNAME ": %s: " fmt, __func__ + ++#include <linux/printk.h> + #include <linux/types.h> + #include <linux/interrupt.h> + #include <linux/wait.h>
patches/collateral-evolutions/network/53-pr_fmt/net_nfc_nci_ntf.patch new file +13 -0
@@ -0,0 +1,13 @@ +--- a/net/nfc/nci/ntf.c ++++ b/net/nfc/nci/ntf.c +@@ -25,8 +25,10 @@ + * + */ + ++#undef pr_fmt + #define pr_fmt(fmt) KBUILD_MODNAME ": %s: " fmt, __func__ + ++#include <linux/printk.h> + #include <linux/types.h> + #include <linux/interrupt.h> + #include <linux/bitops.h>
patches/collateral-evolutions/network/53-pr_fmt/net_nfc_nci_rsp.patch new file +12 -0
@@ -0,0 +1,12 @@ +--- a/net/nfc/nci/rsp.c ++++ b/net/nfc/nci/rsp.c +@@ -25,7 +25,9 @@ + * + */ + ++#undef pr_fmt + #define pr_fmt(fmt) KBUILD_MODNAME ": %s: " fmt, __func__ ++#include <linux/printk.h> + + #include <linux/types.h> + #include <linux/interrupt.h>
patches/collateral-evolutions/network/53-pr_fmt/net_nfc_netlink.patch new file +13 -0
@@ -0,0 +1,13 @@ +--- a/net/nfc/netlink.c ++++ b/net/nfc/netlink.c +@@ -21,8 +21,10 @@ + * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + */ + ++#undef pr_fmt + #define pr_fmt(fmt) KBUILD_MODNAME ": %s: " fmt, __func__ + ++#include <linux/printk.h> + #include <net/genetlink.h> + #include <linux/nfc.h> + #include <linux/slab.h>
patches/collateral-evolutions/network/53-pr_fmt/net_nfc_rawsock.patch new file +13 -0
@@ -0,0 +1,13 @@ +--- a/net/nfc/rawsock.c ++++ b/net/nfc/rawsock.c +@@ -21,8 +21,10 @@ + * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + */ + ++#undef pr_fmt + #define pr_fmt(fmt) KBUILD_MODNAME ": %s: " fmt, __func__ + ++#include <linux/printk.h> + #include <net/tcp_states.h> + #include <linux/nfc.h> + #include <linux/export.h>
patches/collateral-evolutions/network/74-driver-core-constify-data/INFO new file +7 -0
@@ -0,0 +1,7 @@ +This backports: + +commit 9f3b795a626ee79574595e06d1437fe0c7d51d29 +Author: Michał Mirosław <[email protected]> +Date: Fri Feb 1 20:40:17 2013 +0100 + + driver-core: constify data for class_find_device()
patches/collateral-evolutions/network/74-driver-core-constify-data/net_nfc_core.patch new file +14 -0
@@ -0,0 +1,14 @@ +--- a/net/nfc/core.c ++++ b/net/nfc/core.c +@@ -732,7 +732,11 @@ struct class nfc_class = { + }; + EXPORT_SYMBOL(nfc_class); + ++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,9,0)) + static int match_idx(struct device *d, const void *data) ++#else ++static int match_idx(struct device *d, void *data) ++#endif + { + struct nfc_dev *dev = to_nfc_dev(d); + const unsigned int *idx = data;
patches/collateral-evolutions/network/75-module-alias-genl-family/INFO new file +7 -0
@@ -0,0 +1,7 @@ +This backports: + +commit e9412c37082b5c932e83364aaed0c38c2ce33acb +Author: Neil Horman <[email protected]> +Date: Tue May 29 09:30:41 2012 +0000 + + genetlink: Build a generic netlink family module alias
patches/collateral-evolutions/network/75-module-alias-genl-family/net_nfc_core.patch new file +12 -0
@@ -0,0 +1,12 @@ +--- a/net/nfc/core.c ++++ b/net/nfc/core.c +@@ -941,4 +941,9 @@ MODULE_DESCRIPTION("NFC Core ver " VERSI + MODULE_VERSION(VERSION); + MODULE_LICENSE("GPL"); + MODULE_ALIAS_NETPROTO(PF_NFC); ++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,5,0)) + MODULE_ALIAS_GENL_FAMILY(NFC_GENL_NAME); ++#else ++MODULE_ALIAS("net-pf-" __stringify(PF_NETLINK) "-proto-" \ ++__stringify(NETLINK_GENERIC) "-type-" NFC_GENL_NAME); ++#endif
patches/collateral-evolutions/network/76-module-i2c-driver/INFO new file +7 -0
@@ -0,0 +1,7 @@ +This backports: + +commit 7c92784a546d2945b6d6973a30f7134be78eb7a4 +Author: Lars-Peter Clausen <[email protected]> +Date: Wed Nov 16 10:13:36 2011 +0100 + + I2C: Add helper macro for i2c_driver boilerplate
patches/collateral-evolutions/network/76-module-i2c-driver/drivers_nfc_microread_i2c.patch new file +14 -0
@@ -0,0 +1,14 @@ +--- a/drivers/nfc/microread/i2c.c ++++ b/drivers/nfc/microread/i2c.c +@@ -334,7 +334,11 @@ static struct i2c_driver microread_i2c_d + .id_table = microread_i2c_id, + }; + ++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,7,0)) + module_i2c_driver(microread_i2c_driver); ++#else ++module_driver(microread_i2c_driver, i2c_add_driver, i2c_del_driver) ++#endif + + MODULE_LICENSE("GPL"); + MODULE_DESCRIPTION(DRIVER_DESC);
patches/collateral-evolutions/network/76-module-i2c-driver/drivers_nfc_pn544_i2c.patch new file +14 -0
@@ -0,0 +1,14 @@ +--- a/drivers/nfc/pn544/i2c.c ++++ b/drivers/nfc/pn544/i2c.c +@@ -464,7 +464,11 @@ static struct i2c_driver pn544_hci_i2c_d + .remove = pn544_hci_i2c_remove, + }; + ++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,7,0)) + module_i2c_driver(pn544_hci_i2c_driver); ++#else ++module_driver(pn544_hci_i2c_driver, i2c_add_driver, i2c_del_driver) ++#endif + + MODULE_LICENSE("GPL"); + MODULE_DESCRIPTION(DRIVER_DESC);
Signature · 1 line
1.7.10.4
Quoted 50 lines · Thierry Escande
These are NFC patches refreshed on next-20130328
Signed-off-by Thierry Escande <[email protected]>--- .../0005-netlink-portid/net_nfc_netlink.patch | 71 ++++++++++++++++++++ .../network/53-pr_fmt/net_nfc_core.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_hci_command.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_hci_core.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_hci_hcp.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_hci_llc_shdlc.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_llcp_commands.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_llcp_llcp.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_llcp_sock.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_nci_core.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_nci_data.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_nci_ntf.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_nci_rsp.patch | 12 ++++ .../network/53-pr_fmt/net_nfc_netlink.patch | 13 ++++ .../network/53-pr_fmt/net_nfc_rawsock.patch | 13 ++++ .../network/74-driver-core-constify-data/INFO | 7 ++ .../net_nfc_core.patch | 14 ++++ .../network/75-module-alias-genl-family/INFO | 7 ++ .../75-module-alias-genl-family/net_nfc_core.patch | 12 ++++ .../network/76-module-i2c-driver/INFO | 7 ++ .../drivers_nfc_microread_i2c.patch | 14 ++++ .../drivers_nfc_pn544_i2c.patch | 14 ++++ 22 files changed, 327 insertions(+) create mode 100644 patches/collateral-evolutions/network/0005-netlink-portid/net_nfc_netlink.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_core.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_hci_command.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_hci_core.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_hci_hcp.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_hci_llc_shdlc.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_llcp_commands.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_llcp_llcp.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_llcp_sock.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_nci_core.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_nci_data.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_nci_ntf.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_nci_rsp.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_netlink.patch create mode 100644 patches/collateral-evolutions/network/53-pr_fmt/net_nfc_rawsock.patch create mode 100644 patches/collateral-evolutions/network/74-driver-core-constify-data/INFO create mode 100644 patches/collateral-evolutions/network/74-driver-core-constify-data/net_nfc_core.patch create mode 100644 patches/collateral-evolutions/network/75-module-alias-genl-family/INFO create mode 100644 patches/collateral-evolutions/network/75-module-alias-genl-family/net_nfc_core.patch create mode 100644 patches/collateral-evolutions/network/76-module-i2c-driver/INFO create mode 100644 patches/collateral-evolutions/network/76-module-i2c-driver/drivers_nfc_microread_i2c.patch create mode 100644 patches/collateral-evolutions/network/76-module-i2c-driver/drivers_nfc_pn544_i2c.patch
......
Quoted 18 lines
patches/collateral-evolutions/network/75-module-alias-genl-family/INFO new file +7
-0@@ -0,0 +1,7 @@ +This backports: + +commit e9412c37082b5c932e83364aaed0c38c2ce33acb +Author: Neil Horman <[email protected]> +Date: Tue May 29 09:30:41 2012 +0000 + + genetlink: Build a generic netlink family module aliaspatches/collateral-evolutions/network/75-module-alias-genl-family/net_nfc_core.patch new file +2
-0@@ -0,0 +1,12 @@ +--- a/net/nfc/core.c ++++ b/net/nfc/core.c
patches/collateral-evolutions/network/75-module-alias-genl-family/net_nfc_core.patch line 12
Quoted 10 lines
patches/collateral-evolutions/network/75-module-alias-genl-family/net_nfc_core.patch new file +10
-0+@@ -941,4 +941,9 @@ MODULE_DESCRIPTION("NFC Core ver " VERSI + MODULE_VERSION(VERSION); + MODULE_LICENSE("GPL"); + MODULE_ALIAS_NETPROTO(PF_NFC); ++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,5,0)) + MODULE_ALIAS_GENL_FAMILY(NFC_GENL_NAME); ++#else ++MODULE_ALIAS("net-pf-" __stringify(PF_NETLINK) "-proto-" \ ++__stringify(NETLINK_GENERIC) "-type-" NFC_GENL_NAME); ++#endif
I would prefer if you add #define MODULE_ALIAS_GENL_FAMILY() to backport/include/linux/compat-*.h
It looks possible and something in backport/ is preferred over a patch.
Quoted 20 lines
patches/collateral-evolutions/network/76-module-i2c-driver/INFO new file +7
-0@@ -0,0 +1,7 @@ +This backports: + +commit 7c92784a546d2945b6d6973a30f7134be78eb7a4 +Author: Lars-Peter Clausen <[email protected]> +Date: Wed Nov 16 10:13:36 2011 +0100 + + I2C: Add helper macro for i2c_driver boilerplatepatches/collateral-evolutions/network/76-module-i2c-driver/drivers_nfc_microread_i2c.patch new file +1
-0@@ -0,0 +1,14 @@ +--- a/drivers/nfc/microread/i2c.c
patches/collateral-evolutions/network/76-module-i2c-driver/drivers_nfc_microread_i2c.patch line 11
Quoted 10 lines
patches/collateral-evolutions/network/76-module-i2c-driver/drivers_nfc_microread_i2c.patch new file +10
-0++++ b/drivers/nfc/microread/i2c.c +@@ -334,7 +334,11 @@ static struct i2c_driver microread_i2c_d + .id_table = microread_i2c_id, + }; + ++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,7,0)) + module_i2c_driver(microread_i2c_driver); ++#else ++module_driver(microread_i2c_driver, i2c_add_driver, i2c_del_driver) ++#endif
Add this to backport/include/linux/compat-*.h like it was done in:
commit 117e80b649819db203743fb8774a6f1e9c9f93c4
Author: Hauke Mehrtens <[email protected]> Date: Thu Mar 28 20:18:23 2013 +0100
compat: add module_pcmcia_driver
Quoted 10 lines
patches/collateral-evolutions/network/76-module-i2c-driver/drivers_nfc_microread_i2c.patch new file +3
-0+ + MODULE_LICENSE("GPL"); + MODULE_DESCRIPTION(DRIVER_DESC);patches/collateral-evolutions/network/76-module-i2c-driver/drivers_nfc_pn544_i2c.patch new file +1
-0@@ -0,0 +1,14 @@ +--- a/drivers/nfc/pn544/i2c.c
patches/collateral-evolutions/network/76-module-i2c-driver/drivers_nfc_pn544_i2c.patch line 11
Quoted 10 lines
patches/collateral-evolutions/network/76-module-i2c-driver/drivers_nfc_pn544_i2c.patch new file +10
-0++++ b/drivers/nfc/pn544/i2c.c +@@ -464,7 +464,11 @@ static struct i2c_driver pn544_hci_i2c_d + .remove = pn544_hci_i2c_remove, + }; + ++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,7,0)) + module_i2c_driver(pn544_hci_i2c_driver); ++#else ++module_driver(pn544_hci_i2c_driver, i2c_add_driver, i2c_del_driver) ++#endif
same here
Quoted 4 lines
patches/collateral-evolutions/network/76-module-i2c-driver/drivers_nfc_pn544_i2c.patch new file +3
-0+ + MODULE_LICENSE("GPL"); + MODULE_DESCRIPTION(DRIVER_DESC);