/* * nop (passthrough) Link Layer Control * * Copyright (C) 2012 Intel Corporation. All rights reserved. * * This program is free software; you can redistribute it and/or modify it * under the terms and conditions of the GNU General Public License, * version 2, as published by the Free Software Foundation. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, see . */ #include #include "llc.h" struct llc_nop { struct nfc_hci_dev *hdev; xmit_to_drv_t xmit_to_drv; rcv_to_hci_t rcv_to_hci; int tx_headroom; int tx_tailroom; llc_failure_t llc_failure; }; static void *llc_nop_init(struct nfc_hci_dev *hdev, xmit_to_drv_t xmit_to_drv, rcv_to_hci_t rcv_to_hci, int tx_headroom, int tx_tailroom, int *rx_headroom, int *rx_tailroom, llc_failure_t llc_failure) { struct llc_nop *llc_nop; *rx_headroom = 0; *rx_tailroom = 0; llc_nop = kzalloc(sizeof(struct llc_nop), GFP_KERNEL); if (llc_nop == NULL) return NULL; llc_nop->hdev = hdev; llc_nop->xmit_to_drv = xmit_to_drv; llc_nop->rcv_to_hci = rcv_to_hci; llc_nop->tx_headroom = tx_headroom; llc_nop->tx_tailroom = tx_tailroom; llc_nop->llc_failure = llc_failure; return llc_nop; } static void llc_nop_deinit(struct nfc_llc *llc) { kfree(nfc_llc_get_data(llc)); } static int llc_nop_start(struct nfc_llc *llc) { return 0; } static int llc_nop_stop(struct nfc_llc *llc) { return 0; } static void llc_nop_rcv_from_drv(struct nfc_llc *llc, struct sk_buff *skb) { struct llc_nop *llc_nop = nfc_llc_get_data(llc); llc_nop->rcv_to_hci(llc_nop->hdev, skb); } static int llc_nop_xmit_from_hci(struct nfc_llc *llc, struct sk_buff *skb) { struct llc_nop *llc_nop = nfc_llc_get_data(llc); return llc_nop->xmit_to_drv(llc_nop->hdev, skb); } static struct nfc_llc_ops llc_nop_ops = { .init = llc_nop_init, .deinit = llc_nop_deinit, .start = llc_nop_start, .stop = llc_nop_stop, .rcv_from_drv = llc_nop_rcv_from_drv, .xmit_from_hci = llc_nop_xmit_from_hci, }; int nfc_llc_nop_register(void) { return nfc_llc_register(LLC_NOP_NAME, &llc_nop_ops); } te-remove'/>
s'>+1
AgeCommit message (Expand)AuthorFilesLines
2017-02-10net: Fix checkpatch, Missing a blank line after declarationstcharding1-0/+13
2017-02-10net: Fix checkpatch block comments warningstcharding1-32/+33
2017-02-10net: Fix checkpatch whitespace errorstcharding1-19/+20
2017-02-10net: Fix checkpatch WARNING: please, no space before tabstcharding1-71/+71
2017-02-10net/act_pedit: Introduce 'add' operationAmir Vadai1-4/+26
2017-02-10net/act_pedit: Support using offset relative to the conventional network headersAmir Vadai1-16/+180
2017-02-10switchdev: bridge: Offload mc router portsNogah Frankel1-0/+15
2017-02-10bridge: mcast: Merge the mc router ports deletions to one functionNogah Frankel1-15/+9
2017-02-10switchdev: bridge: Offload multicast disabledNogah Frankel1-0/+16
2017-02-10sched: check negative err value to safe one level of indentJiri Pirko1-13/+9
2017-02-10sched: add missing curly braces in else branch in tc_ctl_tfilterJiri Pirko1-1/+2
2017-02-10sched: move err set right before goto errout in tc_ctl_tfilterJiri Pirko1-10/+19
2017-02-10sched: push TC filter protocol creation into a separate functionJiri Pirko1-51/+59
2017-02-10sched: move tcf_proto_destroy and tcf_destroy_chain helpers into cls_apiJiri Pirko13-24/+32
2017-02-10sched: rename tcf_destroy to tcf_destroy_protoJiri Pirko2-6/+6
2017-02-10ipv4: fib: Add events for FIB replace and appendIdo Schimmel1-13/+14
2017-02-10ipv4: fib: Send notification before deleting FIB aliasIdo Schimmel1-7/+7
2017-02-10ipv4: fib: Send deletion notification with actual FIB alias typeIdo Schimmel1-2/+2
2017-02-10ipv4: fib: Only flush FIB aliases belonging to currently flushed tableIdo Schimmel1-1/+2
2017-02-09openvswitch: Pack struct sw_flow_key.Jarno Rajahalme4-34/+39
2017-02-09openvswitch: Add force commit.Jarno Rajahalme1-2/+24
2017-02-09openvswitch: Add original direction conntrack tuple to sw_flow_key.Jarno Rajahalme7-46/+227
2017-02-09openvswitch: Inherit master's labels.Jarno Rajahalme1-14/+31
2017-02-09openvswitch: Refactor labels initialization.Jarno Rajahalme1-42/+62
2017-02-09openvswitch: Simplify labels length logic.Jarno Rajahalme1-11/+9
2017-02-09openvswitch: Unionize ovs_key_ct_label with a u32 array.Jarno Rajahalme1-7/+8
2017-02-09openvswitch: Do not trigger events for unconfirmed connections.Jarno Rajahalme1-6/+22
2017-02-09openvswitch: Use inverted tuple in ovs_ct_find_existing() if NATted.Jarno Rajahalme1-2/+22
2017-02-09openvswitch: Fix comments for skb->_nfctJarno Rajahalme1-7/+7
2017-02-09net: dsa: Fix duplicate object ruleFlorian Fainelli1-1/+0
2017-02-09sctp: implement sender-side procedures for Add Incoming/Outgoing Streams Requ...Xin Long2-0/+106
2017-02-09sctp: add support for generating stream reconf add incoming/outgoing streams ...Xin Long1-0/+46
2017-02-09sctp: implement sender-side procedures for SSN/TSN Reset Request ParameterXin Long2-0/+69
2017-02-09sctp: add support for generating stream reconf ssn/tsn reset request chunkXin Long1-0/+29
2017-02-09sctp: streams should be recovered when it fails to send request.Xin Long1-2/+17
2017-02-08ipv4: fib: Notify about nexthop status changesIdo Schimmel1-0/+33
2017-02-08bridge: vlan tunnel id info range fill size calc cleanupsRoopa Prabhu1-18/+16
2017-02-08gro_cells: move to net/core/gro_cells.cEric Dumazet6-0/+100
2017-02-07Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/netDavid S. Miller