14 Dec, 2020

1 commit

  • This patch provids netlink method to configure the TSN protocols hardwares.
    TSN guaranteed packet transport with bounded low latency, low packet delay
    variation, and low packet loss by hardware and software methods.

    The three basic components of TSN are:

    1. Time synchronization: This was implement by 8021AS which base on the
    IEEE1588 precision Time Protocol. This is configured by the other way
    in kernel.
    8021AS not included in this patch.

    2. Scheduling and traffic shaping and per-stream filter policing:
    This patch support Qbv/Qci/Qbu/8021CB/Qav etc.

    3. Selection of communication paths:
    This patch not support the pure software only TSN protocols(like Qcc)
    but hardware related configuration.

    TSN Protocols supports by this patch: Qbv/Qci/Qbu/Credit-base Shaper(Qav).
    This patch verified on NXP ls1028ardb board.

    Signed-off-by: Po Liu

    Po Liu
     

24 May, 2020

1 commit

  • There's currently only a single devres helper in net/ - devm variant
    of alloc_etherdev. Let's move it to net/devres.c with the intention of
    assing a second one: devm_register_netdev(). This new routine will need
    to know the address of the release function of devm_alloc_etherdev() so
    that it can verify (using devres_find()) that the struct net_device
    that's being passed to it is also resource managed.

    Signed-off-by: Bartosz Golaszewski
    Signed-off-by: David S. Miller

    Bartosz Golaszewski
     

24 Jan, 2020

1 commit

  • Implements the infrastructure for MPTCP sockets.

    MPTCP sockets open one in-kernel TCP socket per subflow. These subflow
    sockets are only managed by the MPTCP socket that owns them and are not
    visible from userspace. This commit allows a userspace program to open
    an MPTCP socket with:

    sock = socket(AF_INET, SOCK_STREAM, IPPROTO_MPTCP);

    The resulting socket is simply a wrapper around a single regular TCP
    socket, without any of the MPTCP protocol implemented over the wire.

    Co-developed-by: Florian Westphal
    Signed-off-by: Florian Westphal
    Co-developed-by: Peter Krystad
    Signed-off-by: Peter Krystad
    Co-developed-by: Matthieu Baerts
    Signed-off-by: Matthieu Baerts
    Co-developed-by: Paolo Abeni
    Signed-off-by: Paolo Abeni
    Signed-off-by: Mat Martineau
    Signed-off-by: Christoph Paasch
    Signed-off-by: David S. Miller

    Mat Martineau
     

13 Dec, 2019

1 commit

  • The ethtool netlink interface is going to be split into multiple files so
    that it will be more convenient to put all of them in a separate directory
    net/ethtool. Start by moving current ethtool.c with ioctl interface into
    this directory and renaming it to ioctl.c.

    Signed-off-by: Michal Kubecek
    Acked-by: Jiri Pirko
    Reviewed-by: Florian Fainelli
    Signed-off-by: David S. Miller

    Michal Kubecek
     

28 Feb, 2019

1 commit

  • We need this functionality for the io_uring file registration, but
    we cannot rely on it since CONFIG_UNIX can be modular. Move the helpers
    to a separate file, that's always builtin to the kernel if CONFIG_UNIX is
    m/y.

    No functional changes in this patch, just moving code around.

    Reviewed-by: Hannes Reinecke
    Acked-by: David S. Miller
    Signed-off-by: Jens Axboe

    Jens Axboe
     

28 Jun, 2018

1 commit

  • With the brand-new syntax extension of Kconfig, we can directly
    check the compiler capability in the configuration phase.

    If the cc-can-link.sh fails, the BPFILTER_UMH is automatically
    hidden by the dependency.

    I also deleted 'default n', which is no-op.

    Signed-off-by: Masahiro Yamada
    Acked-by: Daniel Borkmann
    Acked-by: Alexei Starovoitov
    Signed-off-by: David S. Miller

    Masahiro Yamada
     

05 Jun, 2018

1 commit


24 May, 2018

1 commit

  • bpfilter.ko consists of bpfilter_kern.c (normal kernel module code)
    and user mode helper code that is embedded into bpfilter.ko

    The steps to build bpfilter.ko are the following:
    - main.c is compiled by HOSTCC into the bpfilter_umh elf executable file
    - with quite a bit of objcopy and Makefile magic the bpfilter_umh elf file
    is converted into bpfilter_umh.o object file
    with _binary_net_bpfilter_bpfilter_umh_start and _end symbols
    Example:
    $ nm ./bld_x64/net/bpfilter/bpfilter_umh.o
    0000000000004cf8 T _binary_net_bpfilter_bpfilter_umh_end
    0000000000004cf8 A _binary_net_bpfilter_bpfilter_umh_size
    0000000000000000 T _binary_net_bpfilter_bpfilter_umh_start
    - bpfilter_umh.o and bpfilter_kern.o are linked together into bpfilter.ko

    bpfilter_kern.c is a normal kernel module code that calls
    the fork_usermode_blob() helper to execute part of its own data
    as a user mode process.

    Notice that _binary_net_bpfilter_bpfilter_umh_start - end
    is placed into .init.rodata section, so it's freed as soon as __init
    function of bpfilter.ko is finished.
    As part of __init the bpfilter.ko does first request/reply action
    via two unix pipe provided by fork_usermode_blob() helper to
    make sure that umh is healthy. If not it will kill it via pid.

    Later bpfilter_process_sockopt() will be called from bpfilter hooks
    in get/setsockopt() to pass iptable commands into umh via bpfilter.ko

    If admin does 'rmmod bpfilter' the __exit code bpfilter.ko will
    kill umh as well.

    Signed-off-by: Alexei Starovoitov
    Signed-off-by: David S. Miller

    Alexei Starovoitov
     

04 May, 2018

1 commit

  • In this commit the base structure of the AF_XDP address family is set
    up. Further, we introduce the abilty register a window of user memory
    to the kernel via the XDP_UMEM_REG setsockopt syscall. The memory
    window is viewed by an AF_XDP socket as a set of equally large
    frames. After a user memory registration all frames are "owned" by the
    user application, and not the kernel.

    v2: More robust checks on umem creation and unaccount on error.
    Call set_page_dirty_lock on cleanup.
    Simplified xdp_umem_reg.

    Co-authored-by: Magnus Karlsson
    Signed-off-by: Magnus Karlsson
    Signed-off-by: Björn Töpel
    Signed-off-by: Alexei Starovoitov

    Björn Töpel
     

28 Nov, 2017

1 commit


02 Nov, 2017

1 commit

  • Many source files in the tree are missing licensing information, which
    makes it harder for compliance tools to determine the correct license.

    By default all files without license information are under the default
    license of the kernel, which is GPL version 2.

    Update the files which contain no license information with the 'GPL-2.0'
    SPDX license identifier. The SPDX identifier is a legally binding
    shorthand, which can be used instead of the full boiler plate text.

    This patch is based on work done by Thomas Gleixner and Kate Stewart and
    Philippe Ombredanne.

    How this work was done:

    Patches were generated and checked against linux-4.14-rc6 for a subset of
    the use cases:
    - file had no licensing information it it.
    - file was a */uapi/* one with no licensing information in it,
    - file was a */uapi/* one with existing licensing information,

    Further patches will be generated in subsequent months to fix up cases
    where non-standard license headers were used, and references to license
    had to be inferred by heuristics based on keywords.

    The analysis to determine which SPDX License Identifier to be applied to
    a file was done in a spreadsheet of side by side results from of the
    output of two independent scanners (ScanCode & Windriver) producing SPDX
    tag:value files created by Philippe Ombredanne. Philippe prepared the
    base worksheet, and did an initial spot review of a few 1000 files.

    The 4.13 kernel was the starting point of the analysis with 60,537 files
    assessed. Kate Stewart did a file by file comparison of the scanner
    results in the spreadsheet to determine which SPDX license identifier(s)
    to be applied to the file. She confirmed any determination that was not
    immediately clear with lawyers working with the Linux Foundation.

    Criteria used to select files for SPDX license identifier tagging was:
    - Files considered eligible had to be source code files.
    - Make and config files were included as candidates if they contained >5
    lines of source
    - File already had some variant of a license header in it (even if
    Reviewed-by: Philippe Ombredanne
    Reviewed-by: Thomas Gleixner
    Signed-off-by: Greg Kroah-Hartman

    Greg Kroah-Hartman
     

30 Aug, 2017

1 commit

  • Add a new nsh/ directory. It currently holds only GSO functions but more
    will come: in particular, code shared by openvswitch and tc to manipulate
    NSH headers.

    For now, assume there's no hardware support for NSH segmentation. We can
    always introduce netdev->nsh_features later.

    Signed-off-by: Jiri Benc
    Signed-off-by: David S. Miller

    Jiri Benc
     

29 Aug, 2017

1 commit

  • It's time to get rid of IRDA. It's long been broken, and no one seems
    to use it anymore. So move it to staging and after a while, we can
    delete it from there.

    To start, move the network irda core from net/irda to
    drivers/staging/irda/net/

    Signed-off-by: Greg Kroah-Hartman
    Signed-off-by: David S. Miller

    Greg Kroah-Hartman
     

16 Jun, 2017

1 commit

  • Software implementation of transport layer security, implemented using ULP
    infrastructure. tcp proto_ops are replaced with tls equivalents of sendmsg and
    sendpage.

    Only symmetric crypto is done in the kernel, keys are passed by setsockopt
    after the handshake is complete. All control messages are supported via CMSG
    data - the actual symmetric encryption is the same, just the message type needs
    to be passed separately.

    For user API, please see Documentation patch.

    Pieces that can be shared between hw and sw implementation
    are in tls_main.c

    Signed-off-by: Boris Pismenny
    Signed-off-by: Ilya Lesokhin
    Signed-off-by: Aviad Yehezkel
    Signed-off-by: Dave Watson
    Signed-off-by: David S. Miller

    Dave Watson
     

02 Apr, 2017

1 commit

  • development and testing of networking bpf programs is quite cumbersome.
    Despite availability of user space bpf interpreters the kernel is
    the ultimate authority and execution environment.
    Current test frameworks for TC include creation of netns, veth,
    qdiscs and use of various packet generators just to test functionality
    of a bpf program. XDP testing is even more complicated, since
    qemu needs to be started with gro/gso disabled and precise queue
    configuration, transferring of xdp program from host into guest,
    attaching to virtio/eth0 and generating traffic from the host
    while capturing the results from the guest.

    Moreover analyzing performance bottlenecks in XDP program is
    impossible in virtio environment, since cost of running the program
    is tiny comparing to the overhead of virtio packet processing,
    so performance testing can only be done on physical nic
    with another server generating traffic.

    Furthermore ongoing changes to user space control plane of production
    applications cannot be run on the test servers leaving bpf programs
    stubbed out for testing.

    Last but not least, the upstream llvm changes are validated by the bpf
    backend testsuite which has no ability to test the code generated.

    To improve this situation introduce BPF_PROG_TEST_RUN command
    to test and performance benchmark bpf programs.

    Joint work with Daniel Borkmann.

    Signed-off-by: Alexei Starovoitov
    Acked-by: Daniel Borkmann
    Acked-by: Martin KaFai Lau
    Signed-off-by: David S. Miller

    Alexei Starovoitov
     

04 Feb, 2017

1 commit

  • This module is responsible for the ife encapsulation protocol
    encode/decode logics. That module can:
    - ife_encode: encode skb and reserve space for the ife meta header
    - ife_decode: decode skb and extract the meta header size
    - ife_tlv_meta_encode - encodes one tlv entry into the reserved ife
    header space.
    - ife_tlv_meta_decode - decodes one tlv entry from the packet
    - ife_tlv_meta_next - advance to the next tlv

    Reviewed-by: Jiri Pirko
    Signed-off-by: Yotam Gigi
    Signed-off-by: Jamal Hadi Salim
    Signed-off-by: Roman Mashak
    Signed-off-by: David S. Miller

    Yotam Gigi
     

25 Jan, 2017

1 commit

  • Add a general way for kernel modules to sample packets, without being tied
    to any specific subsystem. This netlink channel can be used by tc,
    iptables, etc. and allow to standardize packet sampling in the kernel.

    For every sampled packet, the psample module adds the following metadata
    fields:

    PSAMPLE_ATTR_IIFINDEX - the packets input ifindex, if applicable

    PSAMPLE_ATTR_OIFINDEX - the packet output ifindex, if applicable

    PSAMPLE_ATTR_ORIGSIZE - the packet's original size, in case it has been
    truncated during sampling

    PSAMPLE_ATTR_SAMPLE_GROUP - the packet's sample group, which is set by the
    user who initiated the sampling. This field allows the user to
    differentiate between several samplers working simultaneously and
    filter packets relevant to him

    PSAMPLE_ATTR_GROUP_SEQ - sequence counter of last sent packet. The
    sequence is kept for each group

    PSAMPLE_ATTR_SAMPLE_RATE - the sampling rate used for sampling the packets

    PSAMPLE_ATTR_DATA - the actual packet bits

    The sampled packets are sent to the PSAMPLE_NL_MCGRP_SAMPLE multicast
    group. In addition, add the GET_GROUPS netlink command which allows the
    user to see the current sample groups, their refcount and sequence number.
    This command currently supports only netlink dump mode.

    Signed-off-by: Yotam Gigi
    Signed-off-by: Jiri Pirko
    Reviewed-by: Jamal Hadi Salim
    Reviewed-by: Simon Horman
    Signed-off-by: David S. Miller

    Yotam Gigi
     

10 Jan, 2017

1 commit

  • * enable smc module loading and unloading
    * register new socket family
    * basic smc socket creation and deletion
    * use backing TCP socket to run CLC (Connection Layer Control)
    handshake of SMC protocol
    * Setup for infiniband traffic is implemented in follow-on patches.
    For now fallback to TCP socket is always used.

    Signed-off-by: Ursula Braun
    Reviewed-by: Utz Bacher
    Signed-off-by: David S. Miller

    Ursula Braun
     

18 Aug, 2016

1 commit

  • This patch introduces a utility for parsing application layer protocol
    messages in a TCP stream. This is a generalization of the mechanism
    implemented of Kernel Connection Multiplexor.

    The API includes a context structure, a set of callbacks, utility
    functions, and a data ready function.

    A stream parser instance is defined by a strparse structure that
    is bound to a TCP socket. The function to initialize the structure
    is:

    int strp_init(struct strparser *strp, struct sock *csk,
    struct strp_callbacks *cb);

    csk is the TCP socket being bound to and cb are the parser callbacks.

    The upper layer calls strp_tcp_data_ready when data is ready on the lower
    socket for strparser to process. This should be called from a data_ready
    callback that is set on the socket:

    void strp_tcp_data_ready(struct strparser *strp);

    A parser is bound to a TCP socket by setting data_ready function to
    strp_tcp_data_ready so that all receive indications on the socket
    go through the parser. This is assumes that sk_user_data is set to
    the strparser structure.

    There are four callbacks.
    - parse_msg is called to parse the message (returns length or error).
    - rcv_msg is called when a complete message has been received
    - read_sock_done is called when data_ready function exits
    - abort_parser is called to abort the parser

    The input to parse_msg is an skbuff which contains next message under
    construction. The backend processing of parse_msg will parse the
    application layer protocol headers to determine the length of
    the message in the stream. The possible return values are:

    >0 : indicates length of successfully parsed message
    0 : indicates more data must be received to parse the message
    -ESTRPIPE : current message should not be processed by the
    kernel, return control of the socket to userspace which
    can proceed to read the messages itself
    other < 0 : Error is parsing, give control back to userspace
    assuming that synchronzation is lost and the stream
    is unrecoverable (application expected to close TCP socket)

    In the case of error return (< 0) strparse will stop the parser
    and report and error to userspace. The application must deal
    with the error. To handle the error the strparser is unbound
    from the TCP socket. If the error indicates that the stream
    TCP socket is at recoverable point (ESTRPIPE) then the application
    can read the TCP socket to process the stream. Once the application
    has dealt with the exceptions in the stream, it may again bind the
    socket to a strparser to continue data operations.

    Note that ENODATA may be returned to the application. In this case
    parse_msg returned -ESTRPIPE, however strparser was unable to maintain
    synchronization of the stream (i.e. some of the message in question
    was already read by the parser).

    strp_pause and strp_unpause are used to provide flow control. For
    instance, if rcv_msg is called but the upper layer can't immediately
    consume the message it can hold the message and pause strparser.

    Signed-off-by: Tom Herbert
    Signed-off-by: David S. Miller

    Tom Herbert
     

20 Jul, 2016

1 commit

  • NCSI spec (DSP0222) defines several objects: package, channel, mode,
    filter, version and statistics etc. This introduces the data structs
    to represent those objects and implement functions to manage them.
    Also, this introduces CONFIG_NET_NCSI for the newly implemented NCSI
    stack.

    * The user (e.g. netdev driver) dereference NCSI device by
    "struct ncsi_dev", which is embedded to "struct ncsi_dev_priv".
    The later one is used by NCSI stack internally.
    * Every NCSI device can have multiple packages simultaneously, up
    to 8 packages. It's represented by "struct ncsi_package" and
    identified by 3-bits ID.
    * Every NCSI package can have multiple channels, up to 32. It's
    represented by "struct ncsi_channel" and identified by 5-bits ID.
    * Every NCSI channel has version, statistics, various modes and
    filters. They are represented by "struct ncsi_channel_version",
    "struct ncsi_channel_stats", "struct ncsi_channel_mode" and
    "struct ncsi_channel_filter" separately.
    * Apart from AEN (Asynchronous Event Notification), the NCSI stack
    works in terms of command and response. This introduces "struct
    ncsi_req" to represent a complete NCSI transaction made of NCSI
    request and response.

    link: https://www.dmtf.org/sites/default/files/standards/documents/DSP0222_1.1.0.pdf
    Signed-off-by: Gavin Shan
    Acked-by: Joel Stanley
    Signed-off-by: David S. Miller

    Gavin Shan
     

09 May, 2016

1 commit

  • Add an implementation of Qualcomm's IPC router protocol, used to
    communicate with service providing remote processors.

    Signed-off-by: Courtney Cavin
    Signed-off-by: Bjorn Andersson
    [bjorn: Cope with 0 being a valid node id and implement RTM_NEWADDR]
    Signed-off-by: Bjorn Andersson
    Signed-off-by: David S. Miller

    Courtney Cavin
     

10 Mar, 2016

1 commit

  • This module implements the Kernel Connection Multiplexor.

    Kernel Connection Multiplexor (KCM) is a facility that provides a
    message based interface over TCP for generic application protocols.
    With KCM an application can efficiently send and receive application
    protocol messages over TCP using datagram sockets.

    For more information see the included Documentation/networking/kcm.txt

    Signed-off-by: Tom Herbert
    Signed-off-by: David S. Miller

    Tom Herbert
     

30 Sep, 2015

1 commit

  • L3 master devices allow users of the abstraction to influence FIB lookups
    for enslaved devices. Current API provides a means for the master device
    to return a specific FIB table for an enslaved device, to return an
    rtable/custom dst and influence the OIF used for fib lookups.

    Signed-off-by: David Ahern
    Signed-off-by: David S. Miller

    David Ahern
     

04 Mar, 2015

1 commit


17 Dec, 2014

1 commit

  • Pull vfs pile #2 from Al Viro:
    "Next pile (and there'll be one or two more).

    The large piece in this one is getting rid of /proc/*/ns/* weirdness;
    among other things, it allows to (finally) make nameidata completely
    opaque outside of fs/namei.c, making for easier further cleanups in
    there"

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs:
    coda_venus_readdir(): use file_inode()
    fs/namei.c: fold link_path_walk() call into path_init()
    path_init(): don't bother with LOOKUP_PARENT in argument
    fs/namei.c: new helper (path_cleanup())
    path_init(): store the "base" pointer to file in nameidata itself
    make default ->i_fop have ->open() fail with ENXIO
    make nameidata completely opaque outside of fs/namei.c
    kill proc_ns completely
    take the targets of /proc/*/ns/* symlinks to separate fs
    bury struct proc_ns in fs/proc
    copy address of proc_ns_ops into ns_common
    new helpers: ns_alloc_inum/ns_free_inum
    make proc_ns_operations work with struct ns_common * instead of void *
    switch the rest of proc_ns_operations to working with &...->ns
    netns: switch ->get()/->put()/->install()/->inum() to working with &net->ns
    make mntns ->get()/->put()/->install()/->inum() work with &mnt_ns->ns
    common object embedded into various struct ....ns

    Linus Torvalds
     

11 Dec, 2014

1 commit

  • As it is, default ->i_fop has NULL ->open() (along with all other methods).
    The only case where it matters is reopening (via procfs symlink) a file that
    didn't get its ->f_op from ->i_fop - anything else will have ->i_fop assigned
    to something sane (default would fail on read/write/ioctl/etc.).

    Unfortunately, such case exists - alloc_file() users, especially
    anon_get_file() ones. There we have tons of opened files of very different
    kinds sharing the same inode. As the result, attempt to reopen those via
    procfs succeeds and you get a descriptor you can't do anything with.

    Moreover, in case of sockets we set ->i_fop that will only be used
    on such reopen attempts - and put a failing ->open() into it to make sure
    those do not succeed.

    It would be simpler to put such ->open() into default ->i_fop and leave
    it unchanged both for anon inode (as we do anyway) and for socket ones. Result:
    * everything going through do_dentry_open() works as it used to
    * sock_no_open() kludge is gone
    * attempts to reopen anon-inode files fail as they really ought to
    * ditto for aio_private_file()
    * ditto for perfmon - this one actually tried to imitate sock_no_open()
    trick, but failed to set ->i_fop, so in the current tree reopens succeed and
    yield completely useless descriptor. Intent clearly had been to fail with
    -ENXIO on such reopens; now it actually does.
    * everything else that used alloc_file() keeps working - it has ->i_fop
    set for its inodes anyway

    Signed-off-by: Al Viro

    Al Viro
     

03 Dec, 2014

1 commit

  • The goal of this is to provide a possibility to support various switch
    chips. Drivers should implement relevant ndos to do so. Now there is
    only one ndo defined:
    - for getting physical switch id is in place.

    Note that user can use random port netdevice to access the switch.

    Signed-off-by: Jiri Pirko
    Reviewed-by: Thomas Graf
    Acked-by: Andy Gospodarek
    Signed-off-by: David S. Miller

    Jiri Pirko
     

12 Jul, 2014

1 commit

  • This patch moves generic code which is used by bluetooth and ieee802154
    6lowpan to a new net/6lowpan directory. This directory contains generic
    6LoWPAN code which is shared between bluetooth and ieee802154 MAC-Layer.

    This is the IPHC - "IPv6 Header Compression" format at the moment. Which
    is described by RFC 6282 [0]. The BLTE 6LoWPAN draft describes that the
    IPHC is the same format like IEEE 802.15.4, see [1].

    Futuremore we can put more code into this directory which is shared
    between BLTE and IEEE 802.15.4 6LoWPAN like RFC 6775 or the routing
    protocol RPL RFC 6550.

    To avoid naming conflicts I renamed 6lowpan-y to ieee802154_6lowpan-y
    in net/ieee802154/Makefile.

    [0] http://tools.ietf.org/html/rfc6282
    [1] http://tools.ietf.org/html/draft-ietf-6lowpan-btle-12#section-3.2
    [2] http://tools.ietf.org/html/rfc6775
    [3] http://tools.ietf.org/html/rfc6550

    Signed-off-by: Alexander Aring
    Acked-by: Jukka Rissanen
    Signed-off-by: Marcel Holtmann

    Alexander Aring
     

16 Jan, 2014

1 commit

  • IEEE 802.15.4 and Bluetooth networking stacks share 6lowpan compression
    code. Instead of introducing Makefile/Kconfig hacks, build this code as
    a separate module referenced from both ieee802154 and bluetooth modules.

    This fixes the following build error observed in some kernel
    configurations:

    net/built-in.o: In function `header_create': 6lowpan.c:(.text+0x166149): undefined reference to `lowpan_header_compress'
    net/built-in.o: In function `bt_6lowpan_recv': (.text+0x166b3c): undefined reference to `lowpan_process_data'

    Reported-by: Randy Dunlap
    Signed-off-by: Dmitry Eremin-Solenikov
    Signed-off-by: David S. Miller

    Dmitry Eremin-Solenikov
     

04 Nov, 2013

1 commit

  • High-availability Seamless Redundancy ("HSR") provides instant failover
    redundancy for Ethernet networks. It requires a special network topology where
    all nodes are connected in a ring (each node having two physical network
    interfaces). It is suited for applications that demand high availability and
    very short reaction time.

    HSR acts on the Ethernet layer, using a registered Ethernet protocol type to
    send special HSR frames in both directions over the ring. The driver creates
    virtual network interfaces that can be used just like any ordinary Linux
    network interface, for IP/TCP/UDP traffic etc. All nodes in the network ring
    must be HSR capable.

    This code is a "best effort" to comply with the HSR standard as described in
    IEC 62439-3:2010 (HSRv0).

    Signed-off-by: Arvid Brodin
    Signed-off-by: David S. Miller

    Arvid Brodin
     

28 May, 2013

1 commit

  • In the case where a non-MPLS packet is received and an MPLS stack is
    added it may well be the case that the original skb is GSO but the
    NIC used for transmit does not support GSO of MPLS packets.

    The aim of this code is to provide GSO in software for MPLS packets
    whose skbs are GSO.

    SKB Usage:

    When an implementation adds an MPLS stack to a non-MPLS packet it should do
    the following to skb metadata:

    * Set skb->inner_protocol to the old non-MPLS ethertype of the packet.
    skb->inner_protocol is added by this patch.

    * Set skb->protocol to the new MPLS ethertype of the packet.

    * Set skb->network_header to correspond to the
    end of the L3 header, including the MPLS label stack.

    I have posted a patch, "[PATCH v3.29] datapath: Add basic MPLS support to
    kernel" which adds MPLS support to the kernel datapath of Open vSwtich.
    That patch sets the above requirements in datapath/actions.c:push_mpls()
    and was used to exercise this code. The datapath patch is against the Open
    vSwtich tree but it is intended that it be added to the Open vSwtich code
    present in the mainline Linux kernel at some point.

    Features:

    I believe that the approach that I have taken is at least partially
    consistent with the handling of other protocols. Jesse, I understand that
    you have some ideas here. I am more than happy to change my implementation.

    This patch adds dev->mpls_features which may be used by devices
    to advertise features supported for MPLS packets.

    A new NETIF_F_MPLS_GSO feature is added for devices which support
    hardware MPLS GSO offload. Currently no devices support this
    and MPLS GSO always falls back to software.

    Alternate Implementation:

    One possible alternate implementation is to teach netif_skb_features()
    and skb_network_protocol() about MPLS, in a similar way to their
    understanding of VLANs. I believe this would avoid the need
    for net/mpls/mpls_gso.c and in particular the calls to
    __skb_push() and __skb_push() in mpls_gso_segment().

    I have decided on the implementation in this patch as it should
    not introduce any overhead in the case where mpls_gso is not compiled
    into the kernel or inserted as a module.

    MPLS GSO suggested by Jesse Gross.
    Based in part on "v4 GRE: Add TCP segmentation offload for GRE"
    by Pravin B Shelar.

    Cc: Jesse Gross
    Cc: Pravin B Shelar
    Signed-off-by: Simon Horman
    Signed-off-by: David S. Miller

    Simon Horman
     

11 Feb, 2013

1 commit

  • VM Sockets allows communication between virtual machines and the hypervisor.
    User level applications both in a virtual machine and on the host can use the
    VM Sockets API, which facilitates fast and efficient communication between
    guest virtual machines and their host. A socket address family, designed to be
    compatible with UDP and TCP at the interface level, is provided.

    Today, VM Sockets is used by various VMware Tools components inside the guest
    for zero-config, network-less access to VMware host services. In addition to
    this, VMware's users are using VM Sockets for various applications, where
    network access of the virtual machine is restricted or non-existent. Examples
    of this are VMs communicating with device proxies for proprietary hardware
    running as host applications and automated testing of applications running
    within virtual machines.

    The VMware VM Sockets are similar to other socket types, like Berkeley UNIX
    socket interface. The VM Sockets module supports both connection-oriented
    stream sockets like TCP, and connectionless datagram sockets like UDP. The VM
    Sockets protocol family is defined as "AF_VSOCK" and the socket operations
    split for SOCK_DGRAM and SOCK_STREAM.

    For additional information about the use of VM Sockets, please refer to the
    VM Sockets Programming Guide available at:

    https://www.vmware.com/support/developer/vmci-sdk/

    Signed-off-by: George Zhang
    Signed-off-by: Dmitry Torokhov
    Signed-off-by: Andy king
    Signed-off-by: David S. Miller

    Andy King
     

01 Feb, 2013

1 commit

  • The original suggestion to delete wanrouter started earlier
    with the mainline commit f0d1b3c2bcc5de8a17af5f2274f7fcde8292b5fc
    ("net/wanrouter: Deprecate and schedule for removal") in May 2012.

    More importantly, Dan Carpenter found[1] that the driver had a
    fundamental breakage introduced back in 2008, with commit
    7be6065b39c3 ("netdevice wanrouter: Convert directly reference of
    netdev->priv"). So we know with certainty that the code hasn't been
    used by anyone willing to at least take the effort to send an e-mail
    report of breakage for at least 4 years.

    This commit does a decouple of the wanrouter subsystem, by going
    after the Makefile/Kconfig and similar files, so that these mainline
    files that we are keeping do not have the big wanrouter file/driver
    deletion commit tied into their history.

    Once this commit is in place, we then can remove the obsolete cyclomx
    drivers and similar that have a dependency on CONFIG_WAN_ROUTER_DRIVERS.

    [1] http://www.spinics.net/lists/netdev/msg218670.html

    Originally-by: Joe Perches
    Cc: Dan Carpenter
    Cc: Arnaldo Carvalho de Melo
    Signed-off-by: Paul Gortmaker

    Paul Gortmaker
     

18 May, 2012

1 commit

  • More spring cleaning!

    The ancient Econet protocol should go. Most of the bug fixes in recent
    years have been fixing security vulnerabilities. The hardware hasn't
    been made since the 90s, it is only interesting as an archeological curiosity.

    For the truly curious, or insomniac, go read up on it.
    http://en.wikipedia.org/wiki/Econet

    Signed-off-by: Stephen Hemminger
    Signed-off-by: David S. Miller

    Stephen Hemminger
     

17 May, 2012

1 commit

  • An interface to allocate and register ieee802154 compatible device.
    The allocated device has the following representation in memory:

    +-----------------------+
    | struct wpan_phy |
    +-----------------------+
    | struct mac802154_priv |
    +-----------------------+
    | driver's private data |
    +-----------------------+

    Used by device drivers to register new instance in the stack.

    Signed-off-by: Alexander Smirnov
    Signed-off-by: David S. Miller

    alex.bluesman.smirnov@gmail.com
     

04 Dec, 2011

1 commit

  • Open vSwitch is a multilayer Ethernet switch targeted at virtualized
    environments. In addition to supporting a variety of features
    expected in a traditional hardware switch, it enables fine-grained
    programmatic extension and flow-based control of the network.
    This control is useful in a wide variety of applications but is
    particularly important in multi-server virtualization deployments,
    which are often characterized by highly dynamic endpoints and the need
    to maintain logical abstractions for multiple tenants.

    The Open vSwitch datapath provides an in-kernel fast path for packet
    forwarding. It is complemented by a userspace daemon, ovs-vswitchd,
    which is able to accept configuration from a variety of sources and
    translate it into packet processing rules.

    See http://openvswitch.org for more information and userspace
    utilities.

    Signed-off-by: Jesse Gross

    Jesse Gross
     

06 Jul, 2011

1 commit

  • The NFC subsystem core is responsible for providing the device driver
    interface. It is also responsible for providing an interface to the control
    operations and data exchange.

    Signed-off-by: Lauro Ramos Venancio
    Signed-off-by: Aloisio Almeida Jr
    Signed-off-by: Samuel Ortiz
    Signed-off-by: John W. Linville

    Lauro Ramos Venancio
     

08 Mar, 2011

1 commit

  • exthdrs_core.c and addrconf_core.c in net/ipv6/ contain bits which
    must be made available even if IPv6 is disabled.

    net/ipv6/Makefile already correctly includes them if CONFIG_IPV6=n
    but net/Makefile prevents entering the subdirectory.

    Signed-off-by: Thomas Graf
    Acked-by: Randy Dunlap
    Signed-off-by: David S. Miller

    Thomas Graf
     

17 Dec, 2010

1 commit

  • B.A.T.M.A.N. (better approach to mobile ad-hoc networking) is a routing
    protocol for multi-hop ad-hoc mesh networks. The networks may be wired or
    wireless. See http://www.open-mesh.org/ for more information and user space
    tools.

    Signed-off-by: Sven Eckelmann
    Signed-off-by: David S. Miller

    Sven Eckelmann
     

21 Oct, 2010

1 commit

  • This factors out protocol and low-level storage parts of ceph into a
    separate libceph module living in net/ceph and include/linux/ceph. This
    is mostly a matter of moving files around. However, a few key pieces
    of the interface change as well:

    - ceph_client becomes ceph_fs_client and ceph_client, where the latter
    captures the mon and osd clients, and the fs_client gets the mds client
    and file system specific pieces.
    - Mount option parsing and debugfs setup is correspondingly broken into
    two pieces.
    - The mon client gets a generic handler callback for otherwise unknown
    messages (mds map, in this case).
    - The basic supported/required feature bits can be expanded (and are by
    ceph_fs_client).

    No functional change, aside from some subtle error handling cases that got
    cleaned up in the refactoring process.

    Signed-off-by: Sage Weil

    Yehuda Sadeh