WO2022214854A1 - Methods and systems for efficient metadata and data delivery between a network interface and applications - Google Patents

Methods and systems for efficient metadata and data delivery between a network interface and applications Download PDF

Info

Publication number
WO2022214854A1
WO2022214854A1 PCT/IB2021/052976 IB2021052976W WO2022214854A1 WO 2022214854 A1 WO2022214854 A1 WO 2022214854A1 IB 2021052976 W IB2021052976 W IB 2021052976W WO 2022214854 A1 WO2022214854 A1 WO 2022214854A1
Authority
WO
WIPO (PCT)
Prior art keywords
metadata
network interface
application
packet
data structure
Prior art date
Application number
PCT/IB2021/052976
Other languages
French (fr)
Inventor
Amir ROOZBEH
Alireza FARSHIN
Dejan Kostic
Gerald Q. MAGUIRE JR.
Tom Francois G. BARBETTE
Original Assignee
Telefonaktiebolaget Lm Ericsson (Publ)
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Telefonaktiebolaget Lm Ericsson (Publ) filed Critical Telefonaktiebolaget Lm Ericsson (Publ)
Priority to PCT/IB2021/052976 priority Critical patent/WO2022214854A1/en
Publication of WO2022214854A1 publication Critical patent/WO2022214854A1/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/4401Bootstrapping
    • G06F9/4411Configuring for operating with peripheral devices; Loading of device drivers
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/22Parsing or analysis of headers

Definitions

  • Embodiments of the invention relate to the field of packet networking; and more specifically, to the efficient metadata and data delivery between a network interface and applications.
  • a network device is an electronic device that communicatively interconnects other electronic devices on the network (e.g., other network devices, end-user devices).
  • Some network devices are “multiple services network devices” that provide support for multiple networking functions (e.g., routing, bridging, switching, Layer 2 aggregation, session border control, Quality of Service, and/or subscriber management), and/or provide support for multiple application services (e.g., data, voice, and video).
  • a network device receives input data, processes the data, and outputs the data following its processing.
  • a network device may receive network packets, and output network packets following their processing.
  • a network device includes one or more processing units on which code is executed for processing the input data. The processing units are coupled with a network interface.
  • a network interface (NI) is an electronic device operative to establish network connections (to transmit and/or receive data using propagating signals) with other electronic devices. For example, a NI receives the data from other network devices, transfers the data to the processing unit(s) for processing, and outputs the processed data towards other network devices.
  • VNF virtualized network function
  • VPP Vector Packet Processor
  • BESS Berkeley Extensible Software Switch
  • Applications typically use kernel-space and/or user-space libraries to interact with a NI. These libraries allocate memory from the network device’s main memory (e.g., DRAM) during their initialization phase (known as buffers) and then the NI driver passes the address of the allocated memory /buffers to the NI.
  • main memory e.g., DRAM
  • the NI When the NI receives packets, it transfers the packets to the location of the buffers (e.g., through a Direct Memory Access or DMA).
  • DMA Direct Memory Access
  • the applications operate on these buffers and follow a similar procedure if they need to send the processed data back to the NI.
  • the embodiments described herein present a solution for efficient input/output transfer in network devices.
  • the solution integrates to network and electronic devices the ability to efficiently transfer packets and metadata from a network interface to an application.
  • the solution advantageously optimizes the amount/size of metadata for Input/Output (I/O) data used by an application consequently reducing the application's footprint.
  • the solution prevents extra operations for making I/O data and the metadata compatible with the application.
  • the solution advantageously enables the application to receive the I/O data, and the metadata with an efficient format and size customized for data processing by the application.
  • One general aspect includes a method in a network device.
  • the method includes receiving information regarding metadata to be used by an application for processing packets received through a network interface of a network interface system; determining, based on the information, a metadata data structure that is customized for the application; updating the application with the metadata data structure, and notifying the network interface system with of the metadata data structure, where the notification causes the network interface system to transfer the metadata to the application according to the metadata data structure.
  • the network device includes a non- transitory machine-readable storage medium that provides instructions that, if executed by a processor, will cause the network device to perform operations including: receiving information regarding metadata to be used by an application for processing packets received through a network interface of a network interface system; determining, based on the information, a metadata data structure that is customized for the application; updating the application with the metadata data structure; and notifying the network interface system with of the metadata data structure, where the notification causes the network interface system to transfer the metadata to the application according to the metadata data structure.
  • Non-transitory machine-readable storage medium may include computer program code which when executed by a processor of a network device carries out operations.
  • the operations includes receiving information regarding metadata to be used by an application for processing packets received through a network interface of a network interface system; determining, based on the information, a metadata data structure that is customized for the application; updating the application with the metadata data structure; and notifying the network interface system with of the metadata data structure, where the notification causes the network interface system to transfer the metadata to the application according to the metadata data structure.
  • One general aspect includes a method in a network interface.
  • the method includes receiving information on a metadata data structure for an application that is to process packets received through the network interface; receiving a packet at the network interface; adding the packet to a receive queue of the network interface; determining, based on the information, whether customized metadata is to be generated in the network interface for the packet; and responsive to determining that the customized metadata is to be generated in the network interface, determining, based on the information, the customized metadata for the packet, and transferring the customized metadata and the packet to the application according to the metadata data structure.
  • the network interface includes a non- transitory machine-readable storage medium that provides instructions that, if executed by a processor, will cause the network interface to perform operations including, receiving information on a metadata data structure for an application that is to process packets received through the network interface; receiving a packet at the network interface; adding the packet to a receive queue of the network interface; determining, based on the information, whether customized metadata is to be generated in the network interface for the packet; and responsive to determining that the customized metadata is to be generated in the network interface, determining, based on the information, the customized metadata for the packet, and transferring the customized metadata and the packet to the application according to the metadata data structure.
  • Non-transitory machine-readable storage medium may include computer program code which when executed by a processor of a network interface carries out operations.
  • the operations includes receiving information on a metadata data structure for an application that is to process packets received through the network interface; receiving a packet at the network interface; adding the packet to a receive queue of the network interface; determining, based on the information, whether customized metadata is to be generated in the network interface for the packet; and responsive to determining that the customized metadata is to be generated in the network interface, determining, based on the information, the customized metadata for the packet, and transferring the customized metadata and the packet to the application according to the metadata data structure.
  • Figure 1 A illustrates a block diagram of a system for efficient metadata transfer to an application, in accordance with some embodiments.
  • Figure IB illustrates a block diagram of an exemplary NI that includes a metadata manager 190, in accordance with some embodiments.
  • Figure 2A illustrates a flow diagram of exemplary operations that can be performed for efficient metadata transfer between a network interface and applications, in accordance with some embodiments.
  • Figure 2B illustrates a flow diagram of exemplary operations 210 that can be performed for analyzing information related to metadata for an application, in accordance with some embodiments.
  • Figure 2C illustrates a flow diagram of exemplary operations that can be performed when a packet is received in a network interface, in accordance with some embodiments.
  • Figure 3 illustrates a flow diagram of exemplary operations that can be performed when a packet is received in a network interface that includes a metadata manager 190, in accordance with some embodiments.
  • Figure 4A illustrates connectivity between network devices (NDs) within an exemplary network, as well as three exemplary implementations of the NDs, according to some embodiments of the invention.
  • Figure 4B illustrates an exemplary way to implement a special-purpose network device according to some embodiments of the invention.
  • FIG. 4C illustrates various exemplary ways in which virtual network elements (VNEs) may be coupled according to some embodiments of the invention.
  • VNEs virtual network elements
  • Figure 4D illustrates a network with a single network element (NE) on each of the NDs, and within this straight forward approach contrasts a traditional distributed approach (commonly used by traditional routers) with a centralized approach for maintaining reachability and forwarding information (also called network control), according to some embodiments of the invention.
  • NE network element
  • Figure 4E illustrates the simple case of where each of the NDs implements a single NE, but a centralized control plane has abstracted multiple of the NEs in different NDs into (to represent) a single NE in one of the virtual network(s), according to some embodiments of the invention.
  • Figure 4F illustrates a case where multiple VNEs are implemented on different NDs and are coupled to each other, and where a centralized control plane has abstracted these multiple VNEs such that they appear as a single VNE within one of the virtual networks, according to some embodiments of the invention.
  • Figure 5 illustrates a general-purpose control plane device with centralized control plane (CCP) software 550), according to some embodiments of the invention.
  • CCP centralized control plane
  • references in the specification to “one embodiment,” “an embodiment,” “an example embodiment,” etc., indicate that the embodiment described may include a particular feature, structure, or characteristic, but every embodiment may not necessarily include the particular feature, structure, or characteristic. Moreover, such phrases are not necessarily referring to the same embodiment. Further, when a particular feature, structure, or characteristic is described in connection with an embodiment, it is submitted that it is within the knowledge of one skilled in the art to affect such feature, structure, or characteristic in connection with other embodiments whether or not explicitly described.
  • Bracketed text and blocks with dashed borders may be used herein to illustrate optional operations that add additional features to embodiments of the invention. However, such notation should not be taken to mean that these are the only options or optional operations, and/or that blocks with solid borders are not optional in certain embodiments of the invention.
  • Coupled is used to indicate that two or more elements, which may or may not be in direct physical or electrical contact with each other, co-operate or interact with each other.
  • Connected is used to indicate the establishment of communication between two or more elements that are coupled with each other.
  • the metadata may include one or more fields and the size of metadata depends on the type of application.
  • the metadata can be needed by one or more applications to operate/process the raw bits of the packets. Some fields of the metadata can be automatically generated by the NI upon receipt of the packet.
  • Different applications usually use common frameworks/libraries to implement their networking functionalities and obtain data and/or metadata from the NI.
  • applications can either use (i) kernel-space interfaces/modules/libraries such as Berkeley sockets API and extended Berkeley Packet Filter (eBPF)/ eXpress Data Path (XDP) or (ii) user-space libraries such as Data Plane Development Kit (DPDK) and netmap to receive/send packets and interact with network interfaces.
  • kernel-space interfaces/modules/libraries such as Berkeley sockets API and extended Berkeley Packet Filter (eBPF)/ eXpress Data Path (XDP)
  • XDP eXpress Data Path
  • DPDK Data Plane Development Kit
  • frameworks/libraries are designed with generality in mind, which prevents them from having customized metadata for different applications.
  • the frameworks and libraries present generic data structures for storing the metadata. Consequently, the applications need to adapt the existing generic data structures of the framework and libraries to their needs.
  • the applications need to copy the metadata generated based on these frameworks to their respective application-specific data structures. Additionally, since different applications might perform different tasks at different stages, to avoid conflicts between these tasks the applications often allocate a general- purpose space in memory for handling the metadata. This space is often larger than the applications’ needs and remains mostly unused. However, the allocation of extra space reduces caches locality and the performance of the system. In addition to the unoptimized size for the metadata, the application-specific data structure used in the applications does not necessarily contain the right order for different tasks. For example, some fields of the metadata might be stored on different cache/memory lines, despite being accessed consecutively, which results in a nonoptimal cache locality and increased access latency in many cases.
  • the driver of the NI passes to the NI addresses of buffers in the main memory for storing the data and metadata for the applications. Due to proprietary design and simplicity, the NI driver often uses vendor-specific data structures for managing the metadata. These vendor-specific data structures are different and independent of the generic data structures defined by the frameworks and libraries used by the applications. Consequently, the NI driver needs to copy /convert the metadata/annotations received from the NI to the generic data structures that are used by the frameworks and libraries.
  • Embodiments disclosed herein address the above and other deficiencies by presenting methods and systems that enable an efficient metadata delivery between input/output devices and applications.
  • Embodiments presented herein enable a metadata data structure determiner to determine a metadata data structure that is customized/optimized for an application; and to inform the NI of the metadata data structure. Informing the NI of the metadata data structure prevents unnecessary and expensive copying/conversion operations of the metadata before the metadata gets delivered to the application.
  • the methods and systems presented herein enable an application-level analysis to optimize/minimize the size of the metadata and/or order of metadata parameters for an application.
  • methods, and systems of metadata management in a NI are described.
  • the embodiments herein present several advantages when compared with existing I/O delivery solutions.
  • the embodiments herein reduce the memory size needed by applications to perform data processing (e.g., packet processing) resulting in improved cache locality.
  • the applications seamlessly interact with NI to exchange customized data-structures for efficient TO delivery from the NI to the applications.
  • the embodiments herein enable the applications to process packets at a faster rate since the operations to resolve formatting conflicts between different metadata data structures are avoided. Additionally, the applications receive relevant metadata from the NI without receiving unused metadata, thereby saving PCIe bandwidth and benefitting from faster I/O data transfers.
  • the embodiments presented herein can enable a cloud provider to use fewer computing resources (e.g., servers/cores) to process applications in general and network functions in particular, which not only reduces the cost of implementations of these network functions, but also decreases energy consumption.
  • Metadata is received.
  • the metadata is to be used by an application for processing packets received through the network interface of network interface system
  • a metadata data structure is determined based on the information.
  • the metadata data structure is customized for the application.
  • the application is updated with the metadata data structure, and the network interface system is notified with of the metadata data structure.
  • the notification causes the network interface system to transfer metadata to the application according to the metadata data structure.
  • a network interface receives information on a metadata data structure for an application that is to process packets received through the network interface.
  • the packet is added to a receive queue of the network interface.
  • the network interface determines, based on the information, whether customized metadata is to be generated in the network interface for the packet; and responsive to determining that the customized metadata is to be generated in the network interface, the network interface determines, based on the information, the customized metadata for the packet, and transfers the customized metadata and the packet to the application according to the metadata data structure.
  • FIG. 1A illustrates a block diagram of a system 100 for efficient metadata transfer to an application, in accordance with some embodiments.
  • the system 100 includes a network device 102.
  • the network device 102 includes a processing unit 160, a memory subsystem 164 that includes a main memory 166 and/or a cache 162, and a network interface (NI) 110.
  • the network device 102 is operative to be coupled with one or more other network devices through the NI 110.
  • the network device 102 further includes a network interface driver 172, optional networking libraries 174, optional packet processing framework(s) 176, one or more application(s) 178A-N, and a metadata data structure determiner (MDSD) 180.
  • MDSD metadata data structure determiner
  • the network interface 110 and the NI driver 172 form the NI system 120.
  • the NI driver 172 is operative to operate or controls the NI.
  • the NI driver 172 provides an interface to NI 110, enabling operating systems, the networking libraries 174, the packet processing framework 176, and the applications 178A-N to access the NI.
  • NI driver 172 communicates with NI 110 through a bus or a communications subsystem to which NI 110 connects. When a calling program invokes a routine in the driver, the driver issues commands to the device.
  • the NI 110 is operative to establish network connections (to transmit and/or receive data using propagating signals) for the network device 102 with other electronic devices.
  • the NI (or the NI in combination with a processor unit of the network device executing code) may perform any formatting, coding, or translating to allow the network device to send and receive data whether over a wired and/or a wireless connection.
  • the processing unit 160 includes one or more processor(s) (not illustrated) that are coupled with non-transitory computer readable storage media, such as the memory subsystem 164.
  • the memory subsystem 164 can include a cache 162 and/or a main memory 166.
  • the cache 162 is part of the processing unit 160.
  • the processor(s) execute code that is stored in non-transitory computer readable storage media to instantiate one or more sets of one or more applications 178A-N, optional networking libraries 174, optional packet processing framework(s) 176, and/or NI driver 172.
  • the application(s) 178A-N process data/packets received from the NI 110.
  • the data can be received directly from the NI 110 (through the cache 162) or from the main memory 166.
  • the NI 110 is connected to the processing unit 160 and the main memory 166 through a communication bus.
  • the NI 110 can be implemented as described with reference to Figure IB. In other embodiments, the NI 110 may include additional elements that are not illustrated in Figure IB.
  • Figure IB illustrates a block diagram of an exemplary NI 110, in accordance with some embodiments.
  • the NI 110 includes an input/output (I/O) controller 105 that is operative to send and receive data (e.g., packets) from an external electronic device.
  • I/O input/output
  • the I/O controller 105 may facilitate in connecting the network device to other electronic devices allowing them to communicate via wire through plugging in a cable to a physical port connected to the controller.
  • the I/O controller 105 is a Media Access Controller (MAC).
  • a physical NI may comprise radio circuitry capable of receiving data from other electronic devices over a wireless connection and/or sending data out to other devices via a wireless connection.
  • This radio circuitry may include transmitter(s), receiver(s), and/or transceiver(s) suitable for radiofrequency communication.
  • the radio circuitry may convert digital data into a radio signal having the appropriate parameters (e.g., frequency, timing, channel, bandwidth, etc ).
  • the radio signal may then be transmitted via antennas to the appropriate recipient(s).
  • the NI manager 130 is operative to decide how a packet is distributed among available receive queues, RX queues Ql-QN. These queues are used to store packets/data that are to be processed by the processing unit 160.
  • receive side scaling (RSS) mechanism can be used to distribute/schedule data to the RX queues Ql-QN.
  • RSS is a network driver technology that enables the efficient distribution of network receive packets across multiple RX queues based on the hash of different fields of a packet.
  • NI 110 provides advanced flow-steering techniques which support advanced filtering of packets. These advanced filtering techniques enable the NI to direct the received packets to different queues based on a rule.
  • the NI 110 also includes transmit queues, TX queues PI -PM.
  • the TX queues PI -PM receive processed data/packets from the processing unit 160 to be output from the NI 110.
  • the TX queues Pl-PM can receive packets/data from the main memory 166 and/or from the cache 162.
  • the NI 110 further includes a memory communication manager 140.
  • the memory communication manager 140 is operative to transfer packets/data to and from the memory of a processing unit 160, e.g., main memory 166.
  • Two mechanisms can be used for transferring data/packets from the NI 110 to the processing unit 160, 1) a first mechanism where data/packets are stored in main memory 166, 2) a second mechanisms where the packets/data are directly sent to the processing unit 160.
  • the latter technique is sometimes referred to as direct cache access, Data Direct I/O (DDIO), or cache stashing.
  • DDIO Data Direct I/O
  • the data/packets are directly stored in the cache of the processing unit 160, e.g., cache 162, or alternatively the data packets are directly sent to registers of the processing unit 160. Direct transmission of data/packets to the processing unit 160 is performed without transmission of the data/packets to the main memory 166.
  • the data/packets are then processed by the applications 178A-N from the cache 162 or from the registers 165.
  • the data is stored in the main memory 166, the data is retrieved by the application 178A-N and stored in the cache before being processed by the applications or in registers.
  • the NI 110 includes an NI manager 130.
  • the NI manager 130 is operative to perform multiple tasks that may include packet classification, packet filtering, and scheduling. In some embodiments, the scheduling can be performed based on the indication 194 in the information 192 regarding a metadata data structure.
  • the NI manager 130 includes the metadata manager 190. While in some embodiments, the NI is described as including the metadata manager 190 for enabling generation of metadata that is customized for applications by the NI, in other embodiments, the NI may not include the metadata manager 190. The operations of an NI including the metadata manager 190 are described in further detail below with reference to Figure 3.
  • the metadata manager 190 includes information 192 regarding a metadata data structure for an application.
  • the information 192 can be received from the MDSD 180, the NI driver 172, and/or the applications 178A-N.
  • the information 192 is used by the NI 110 to determine whether a customized metadata data structure is to be used for determining metadata for packets, and to determine the customized metadata when applicable.
  • the metadata manager 190 can include information for each queue from the queues of the NI.
  • the information 192 can include an identifier 194 of a queue of the network interface that is associated with the application 178A, an indication 195 of the metadata data structure to be used for the queue, and an optional indication 194 of additional parameters for metadata that are to be generated by the NI 110.
  • the queue of the network interface is associated with an application 178A when the queue is configured to receive packets destined for processing by the application 178A.
  • the indication 195 of the metadata data structure identifies the list of parameters of the metadata data structure, their format, and order. In some embodiments, the indication 195 is the metadata data structure, in other embodiments, the indication 195 identifies the location of the metadata data structure (e.g., an address in memory, etc ).
  • the NI system 120 is operative to receive metadata data structures 182A-N and transfer data/metadata to an application 178A-N according to the metadata data structures according to multiple embodiments described with reference to Figures 2A-3.
  • the operations in the flow diagrams of Figures 2A-3 will be described with reference to the exemplary embodiments of the other figures. However, it should be understood that the operations of the flow diagrams can be performed by embodiments of the invention other than those discussed with reference to the other figures, and the embodiments of the invention discussed with reference to these other figures can perform operations different than those discussed with reference to the flow diagrams. In the following description similar reference numbers correspond to similar components.
  • processing packets/data uses additional data known as metadata.
  • the metadata can be defined by the NI driver and/or the application itself.
  • the metadata includes information on the raw packet received through the NI, such as a length of the packet, a timestamp for the packet, a checksum, and pointers to different protocol stacks in the packet or to metadata that are derived and used by the applications.
  • the metadata can include user/application metadata (which is sometimes referred to as packet annotations) that is used during the data processing.
  • the application metadata can be calculated/extracted from the packet and used during processing of the packet by the application and/or the network interface.
  • the application metadata can include one or more of headers, labels, networking addresses, etc. (such as Virtual Local Area Network (VLAN) identifier (ID), Multiprotocol Label Switching (MPLS), source & destination Internet Protocol addresses & ports, statistics, and Wi-Fi association, etc.).
  • VLAN Virtual Local Area Network
  • MPLS Multiprotocol Label Switching
  • Source & destination Internet Protocol addresses & ports such as Source & destination Internet Protocol addresses & ports, statistics, and Wi-Fi association, etc.
  • the method 200 can be performed by processing logic that can include hardware (e.g., processing device, circuitry, dedicated logic, programmable logic, microcode, hardware of a device, integrated circuit, etc.), software (e.g., instructions run or executed on a processing device), or a combination thereof.
  • processing logic can include hardware (e.g., processing device, circuitry, dedicated logic, programmable logic, microcode, hardware of a device, integrated circuit, etc.), software (e.g., instructions run or executed on a processing device), or a combination thereof.
  • the method 200 is performed by MDSD 180 of Figure 1 A.
  • MDSD 180 receives information, e.g., information 181A-N, regarding metadata.
  • the metadata is to be used by an application 178A for processing packets received through the network interface 110 of the network interface system 120.
  • the information 181A represents the characteristics and/or requirements of the application 178A.
  • the information 181A can include 1) parameters needed by the application 178A to process packets, 2) an order of access of the parameters by the application 178A, and 3) dependencies between the parameters.
  • the information 181A can be generated or determined from a data structure 179A-N of the application.
  • the information can be defined as a graph where a node of the graph receives input data, performs actions (adds/changes/removes the data), and passes the output of this action to a next node of the graph.
  • the information regarding the metadata can also include a size of memory needed by the application for storing the metadata during the processing of packets received from the NT
  • some or all the information 181 A is received from the application 178A. Additionally or alternatively some or all the information 181 A is received from a user (e.g., a developer of the application 178A, etc.) or a system administrator (e.g., an administrator of the network including the network device 102).
  • MDSD 180 may receive one or more information, e.g., 181A-N, from one or more applications 178A-N respectively. Each information will be used to customize processing/generation of metadata for the associated application from the applications 178A-N.
  • the application 178A is a networking function.
  • the application 178A can implement a forwarding function implemented on top of a packet processing framework 176 or networking library 174.
  • the application 178A and/or packet processing framework provides to MDSD 180, a graph defining the information 181 A as well as any data structures (e.g., Packet class) defined by the packet processing framework or the library.
  • the graph sent from the application or packet processing framework contains a single node where the source and destination Media Access Control (MAC) addresses are swapped.
  • MDSD 180 is informed that these two fields represent the information needed for the application.
  • the application uses these two fields for processing packets received at the network interface 110.
  • the application 178A needs to access the destination MAC address first and then the source MAC address. Additionally, the application needs a pointer for pointing to the location of MAC addresses in the packet buffer and the address of the packet. In this example, other fields such as packet size, timestamp, and/or other metadata that may be automatically generated by the NI 110 are not needed by the application 178A for processing a packet.
  • MDSD 180 determines, based on the information 181 A, a metadata data structure 182 A for the application 178A.
  • MDSD 180 determines a metadata data structure, e g., 182A-N for each one of the applications, respectively.
  • a first metadata data structure 182A is determined for a first application, e.g., application 178A
  • a second metadata data structure 182N is determined for a second application, e g., application 178N.
  • the two metadata data structures are identical. In other embodiments, the two metadata data structures are different.
  • the metadata data structure 182A is customized for the application 178A.
  • the metadata data structure 182A is determined to optimize transfer of metadata from NI 110 to the application 178A. Additionally or alternatively, the metadata data structure 182A is determined to optimize the metadata for usage of application, e g., by re-ordering the access to certain fields/parameters.
  • MDSD 180 analyses the information to determine an appropriate order and priority for transferring the multiple parameters used by the application 178A during the processing of the packets. For example, MDSD 180 can analyze the graph that represents the operations performed on and dependencies between the parameters (e.g., variables and fields) of an application 178A. In some embodiments, additionally or alternatively to analyzing the graph, MDSD 180 performs live variable analysis (also referred to as liveness analysis) on different variables of the application.
  • live variable analysis also referred to as liveness analysis
  • MDSD 180 calculates the variables that are live at each point in time when the application 178A is processing a packet. A variable is live at some point in time if it holds a value that can be needed in the future, or equivalently if its value may be read before the next time the variable is written to. While in some embodiments, MDSD 180 performs the liveness analysis, in other embodiments, MDSD 180 does not perform the liveness analysis.
  • MDSD 180 can perform the operations of Figure 2B.
  • Figure 2B illustrates a flow diagram of exemplary operations 210 that can be performed for analyzing information related to metadata for an application, in accordance with some embodiments.
  • MDSD 180 identifies a first set of one or more parameters. The first set of parameters includes parameters which are provided in the information but are not used by the application.
  • MDSD 180 identifies a second set of parameters, where a parameter from the second set of parameters is used by the application 178A.
  • MDSD 180 identifies an order of access of the parameters used by the application 178A.
  • MDSD 180 identifies one or more dependencies between one or more parameters of the parameters that are used by the application 178A.
  • MDSD 180 may perform one or a combination of the operations 212-218.
  • MDSD 180 is then operative to generate a metadata data structure 182A that is customized for the application.
  • the metadata data structure optimizes the storage of the parameters used by the application 178A based on this analysis. Additionally or alternatively, the metadata data structure 182A is determined to optimize the metadata for usage of application, e.g., by re ordering the access to certain fields/parameters.
  • the new metadata data structure may include less parameters as the one included in the information (181 A) and/or have parameters presented in a different order than the order of parameters in the information (181 A) and/or may include more parameters as the one included in the information.
  • the reordering of the parameters in the metadata data structure can be performed based on different criteria, such as the order of access, the popularity of accessed fields, and/or other metrics.
  • MDSD 180 generates a metadata data structure 182A that ensures that the parameters that are accessed consecutively by the application 178A are located on the same or two consecutive cache lines so that they could be fetched faster by a processor during the processing of their related packet (e.g., by efficiently taking advantage of processors prefetching capability).
  • generating the metadata data structure 182A includes removing parameters that are not used by the application.
  • generating the metadata data structure 182A includes removing duplicate occurrences of a parameters that is accessed multiple times by the application, if applicable.
  • MDSD 180 removes all the unnecessary fields from the packet processing framework/library data structure, and keeps a pointer to the source and destination MAC addresses based on the accessed order on the same cache line (e.g., Destination MAC address followed by source MAC address) and a pointer to the packet.
  • a pointer to the source and destination MAC addresses based on the accessed order on the same cache line (e.g., Destination MAC address followed by source MAC address) and a pointer to the packet.
  • MDSD 180 updates the application 178A with the metadata data structure 182A.
  • MDSD 180 notifies the application about the metadata data structure 182 A such that the application 178A can use a customized data structure for accessing metadata when processing data received from the NI.
  • MDSD 180 can optionally notify the networking libraries 174 and/or the packet processing framework 176 about the metadata data structure 182A such that the elements of the framework 176 or the libraries 174 used by the application are updated to use the customized metadata data structure.
  • MDSD 180 communicates with the application 178A through a communication interface that is part of the application (e g., REST API or other).
  • MDSD 180 uses a compiler tool chain to modify the source code/intermediate code/binary code of the application 178A and replaces the default application data structures with the newly customized metadata data structure 182A.
  • the update of the application 178A with the new metadata data structure 182A causes the application to provide addresses to this metadata data structure and buffers to the network interface
  • the application can send these addresses to the NI driver 172 that transfers them to the NI 110.
  • the NI 110 is then operative to use these addresses to transfer data (e.g., metadata and packets) to the application.
  • the transfer of data can be direct (to the cache 162) or via the main memory 166.
  • MDSD notifies application 178A about the new metadata data structure for packet processing that contains pointers to the destination and source MAC addresses and a pointer to the packet. If there is no communication interface with the application 178A, MDSD 180 can use available tools (e.g., LLVM tool chain) to modify the source code/binary /intermediate code of the application, the networking libraries 174, and/or packet processing framework 176.
  • tools e.g., LLVM tool chain
  • the MDSD 180 notifies the network interface system 120 with the metadata data structure 182A.
  • the notification of the network interface system 120 causes the network interface system 120 to transfer metadata of packets to the application 178A according to the metadata data structure 182A.
  • MDSD 180 can interact with the NI driver 172 to transmit the metadata data structure 182A.
  • the NI driver 172 can receive one or more metadata data structures 182A-N for one or more of the applications 178A-N.
  • the MDSD 180 can interact with the NI 110 to transmit the metadata data structure 182A.
  • the NI 110 can receive one or more metadata data structures 182A-N for one or more of the applications 178A-N.
  • the NI driver 172 is operative (e.g., via virtualized conversion functions) to generate and/or convert metadata of packets received in the NI 110 and transfer the metadata to the application 178 A according to the metadata data structure.
  • the NI driver 172 can be programmed to generate metadata according to the metadata data structure 182A, the NI 110 is not programmable or extendable to include the metadata data structure 182A.
  • the programmability of the NI driver 172 enables MDSD 180 to pass to the NI driver 172 metadata data structures 182A-N that are customized for respective applications 178A-N, as opposed to existing solutions where the NI driver only receives standard/common data structures used by the libraries/frameworks.
  • the generation of the metadata for the packet based on the metadata data structure can be performed according to the operations of Figure 2C.
  • FIG. 2C illustrates a flow diagram of exemplary operations 220 that can be performed when a packet is received in a network interface, in accordance with some embodiments.
  • information regarding a metadata data structure 182A is received.
  • the information is received by the NI driver 172.
  • the network interface 110 receives a packet.
  • the packet is to be processed by the application 178 A.
  • the NI 110 adds the packet to a queue of the network interface 110.
  • the NI 110 determines metadata for the packet based on a data structure of the NI 110.
  • the NI 110 stores the metadata in registers or memory available at the NI 110.
  • the NI 110 may determine metadata such as timestamp, size of a packet, etc. and store them internally in registers or memory available at the NI.
  • the determined metadata may or may not be needed by the application 178A.
  • the NI system 120 transfers updated metadata and the packet to the application according to the metadata data structure 182A. Transferring the updated metadata includes generating, at operation 229, the updated metadata based on the metadata data structure 182A and the metadata generated by the NI 110 for the packet.
  • the determination of the updated metadata can include converting the metadata that is generated in the NTs registers/memory into a format defined by the metadata data structure 182A of the application 178A (e.g., reordering the metadata, removing some metadata, etc.). Additionally or alternatively, the determination of the updated metadata can include generating additional metadata that is not stored in the NT s registers. Transferring the updated metadata further includes storing the updated metadata to the network device’s memory subsystem 164 (e.g., to the cache or the main memory) based on the metadata data structure 182A. The transfer of the updated metadata for the packet allows an efficient access of the metadata by the application.
  • the NI driver 172 retrieves the metadata of the NI 110 and stores the pointers to the destination and source MAC addresses and the pointer to the packet as identified in the metadata data structure 182A in the memory subsystem 164 to be accessed by the application 178A.
  • the embodiments described herein, allow for a faster generation of the metadata for the application 178A that avoids unnecessary conversion/copying of data in memory.
  • the embodiments herein avoid two conversions and replaces the conversions of previously existing techniques (e.g., (i) from NI registers/memory to NI driver specific data structures and (ii) from NIC driver data structures to the generic data structures of the framework and libraries, and (iii) from the libraries’ data structures to the application-specific data structures) with one conversion from NI’s registers into a metadata data structure that is customized for the application 178A.
  • the application is now operative to access the data/packets received in the NI in an optimized format.
  • the NI 110 includes a metadata manager 190 that is operative to receive information regarding the metadata data structure and directly generate and store the metadata for a packet according to the metadata data structure without the need of an intermediary operation of storing this information in a data structure of the network interface, and without the need for conversion of the information from the NI’s data structure into the metadata data structure that is customized for the application. While some embodiments described above can be performed in combination with the embodiments described below that include a metadata manager, in other embodiments, these two mechanisms can be implemented separately and independently.
  • the network device 102 may include either one of the MDSD 180 and the metadata manager 190 providing an efficient I/O data delivery to the application when compared with existing mechanisms.
  • the network device 102 includes the MDSD 180 and the metadata manager 190 providing a more efficient I O data delivery to the application, as it prevents all unnecessary operations.
  • Figure 3 illustrates a flow diagram of exemplary operations 300 that can be performed in a network interface for generating metadata according to a metadata data structure, in accordance with some embodiments.
  • the embodiments herein enable different queues of the NI 110 to use different metadata data structures for generation of metadata for multiple applications 182A-N.
  • the metadata manager 190 is further operative to use additional NI offloading features to create/compute the metadata.
  • NI 110 can be operative to prefill some packet metadata fields in the metadata data structures so that the application can skip extracting/computing these fields.
  • the network interface 110 receives information 192 regarding a metadata data structure for an application.
  • the information 192 can include an identifier 194 of a queue of the network interface that is associated with the application 178A, the metadata data structure to be used for the queue, and an optional indication 194 of additional parameters for metadata that are to be generated by the NI 110.
  • the queue of the network interface is associated with an application 178A when the queue is configured to receive packets destined for processing by the application 178A.
  • the operation 302 can be performed during an initial configuration phase of the network interface.
  • the operation 302 can be performed when the application starts operating. Following the configuration of the network interface 110, the network interface can start receiving packets for the applications.
  • a packet is received.
  • the packet is added to the queue, at operation 306.
  • the network interface 110 determines, at operation 308, based on the information 192, whether customized metadata is to be generated in the network interface for the packet or NTs default metadata should be generated.
  • the NI manager 130 can interact with the memory communication manager 140 to determine whether there are any memory addresses associated with the receive queue to which the packet is added.
  • the NI manager 130 interacts with the metadata manager 190 to determine, based on the information 192, the metadata that needs to be generated for the packet in the receive queue.
  • the NI manager 130 determines that the metadata that needs to be generated includes default metadata, which does not include additional metadata customized for the application 178A.
  • the NI manager 130 may determine that the metadata is the default metadata if there is no identification 195 of metadata data structure for the associated receive queue in the information 192. Additionally or alternatively, the NI manager 130 determines that the metadata that needs to be generated includes metadata customized for the application 178 A based on the metadata data structure identified in the information 192.
  • the flow moves to operation 310.
  • the NI system 120 transfers the packet to the application and metadata generated according to the NI’s default data structure to the driver 172.
  • the flow moves to operation 312.
  • the NI 110 determines, based on the information 192 the customized metadata for the packet.
  • the metadata includes customized metadata that is generated according to the metadata data structure 182A for the application 178A.
  • the customized metadata can be generated by the NI 110, e.g., the NI manager 130.
  • the NI manager 130 can interact with the packet in the receive queue to calculate and/or extract the customized metadata.
  • the generation of the customized metadata can include reordering parameters of the metadata according to an order defined in the metadata data structure 182A.
  • the generation of the customized metadata can include avoiding the generation of default fields/parameters that would otherwise have been generated according to the default data structure of the NI.
  • the NI manager 130 notifies the memory communication manager 140 to transfer the packet and its associated metadata to application.
  • Transferring the packet and the metadata to the application can include directly transferring them to the application (to the cache 162 or registers of the processing unit 160) or storing the packet and the metadata in the main memory 166.
  • the metadata for a packet that is to be processed by an application is determined at the network interface according to a customized metadata data structure for the application.
  • the network interface 110 is operative to transfer metadata to the first application 178A according to a first metadata data structure and transfer metadata to the second application 178N according to a second metadata data structure.
  • the network interface 110 is operative to customize the metadata and generate the customized metadata without the need for multiple conversions and/or copying of data in the memory subsystem 164. While embodiments herein are described with the network interface 110 receiving a metadata data structure 182A that optimizes transfer of the metadata from the network interface 110 to the application and/or is optimized for usage of application, in other embodiments, the network interface 110 can receive a metadata data structure for the application that is not optimized. For example, the metadata data structure can be received from the application without having been modified by a metadata data structure determiner 180 as described above.
  • An electronic device stores and transmits (internally and/or with other electronic devices over a network) code (which is composed of software instructions and which is sometimes referred to as computer program code or a computer program) and/or data using machine-readable media (also called computer-readable media), such as machine-readable storage media (e.g., magnetic disks, optical disks, solid state drives, read only memory (ROM), flash memory devices, phase change memory) and machine-readable transmission media (also called a carrier) (e.g., electrical, optical, radio, acoustical or other form of propagated signals - such as carrier waves, infrared signals).
  • machine-readable media also called computer-readable media
  • machine-readable storage media e.g., magnetic disks, optical disks, solid state drives, read only memory (ROM), flash memory devices, phase change memory
  • machine-readable transmission media also called a carrier
  • carrier e.g., electrical, optical, radio, acoustical or other form of propagated signals - such as carrier waves, inf
  • an electronic device e.g., a computer
  • hardware and software such as a set of one or more processors (e.g., wherein a processor is a microprocessor, controller, microcontroller, central processing unit, digital signal processor, application specific integrated circuit, field programmable gate array, other electronic circuitry, a combination of one or more of the preceding) coupled to one or more machine-readable storage media to store code for execution on the set of processors and/or to store data.
  • processors e.g., wherein a processor is a microprocessor, controller, microcontroller, central processing unit, digital signal processor, application specific integrated circuit, field programmable gate array, other electronic circuitry, a combination of one or more of the preceding
  • an electronic device may include non-volatile memory containing the code since the non-volatile memory can persist code/data even when the electronic device is turned off (when power is removed), and while the electronic device is turned on that part of the code that is to be executed by the processor(s) of that electronic device is typically copied from the slower non volatile memory into volatile memory (e g., dynamic random access memory (DRAM), static random access memory (SRAM)) of that electronic device.
  • Typical electronic devices also include a set or one or more physical network interface(s) (NI(s)) to establish network connections (to transmit and/or receive code and/or data using propagating signals) with other electronic devices.
  • NI(s) physical network interface
  • a physical NI may comprise radio circuitry capable of receiving data from other electronic devices over a wireless connection and/or sending data out to other devices via a wireless connection.
  • This radio circuitry may include transmitted s), receiver(s), and/or transceiver(s) suitable for radiofrequency communication.
  • the radio circuitry may convert digital data into a radio signal having the appropriate parameters (e.g., frequency, timing, channel, bandwidth, etc.). The radio signal may then be transmitted via antennas to the appropriate recipient(s).
  • the set of physical NI(s) may comprise network interface controller(s) (NICs), also known as a network interface card, network adapter, or local area network (LAN) adapter.
  • NICs network interface controller
  • the NIC(s) may facilitate in connecting the electronic device to other electronic devices allowing them to communicate via wire through plugging in a cable to a physical port connected to a NIC.
  • One or more parts of an embodiment of the invention may be implemented using different combinations of software, firmware, and/or hardware.
  • Figure 4A illustrates connectivity between network devices (NDs) within an exemplary network, as well as three exemplary implementations of the NDs, according to some embodiments of the invention.
  • Figure 4A shows NDs 400A-H, and their connectivity by way of lines between 400A-400B, 400B-400C, 400C-400D, 400D-400E, 400E-400F, 400F-400G, and 400A-400G, as well as between 400H and each of 400A, 400C, 400D, and 400G.
  • These NDs are physical devices, and the connectivity between these NDs can be wireless or wired (often referred to as a link).
  • NDs 400A, 400E, and 400F An additional line extending from NDs 400A, 400E, and 400F illustrates that these NDs act as ingress and egress points for the network (and thus, these NDs are sometimes referred to as edge NDs; while the other NDs may be called core NDs).
  • Two of the exemplary ND implementations in Figure 4A are: 1) a special-purpose network device 402 that uses custom application-specific integrated-circuits (ASICs) and a special-purpose operating system (OS); and 2) a general purpose network device 404 that uses common off-the-shelf (COTS) processors and a standard OS.
  • ASICs application-specific integrated-circuits
  • OS special-purpose operating system
  • COTS common off-the-shelf
  • the special-purpose network device 402 includes networking hardware 410 comprising a set of one or more processor(s) 412, forwarding resource(s) 414 (which typically include one or more ASICs and/or network processors), and physical network interfaces (NIs) 416 (through which network connections are made, such as those shown by the connectivity between NDs 400A-H), as well as non-transitory machine readable storage media 418 having stored therein networking software 420.
  • the networking software 420 may be executed by the networking hardware 410 to instantiate a set of one or more networking software instance(s) 422.
  • Each of the networking software instance(s) 422, and that part of the networking hardware 410 that executes that network software instance form a separate virtual network element 430A-R.
  • Each of the virtual network element(s) (VNEs) 430A-R includes a control communication and configuration module 432A-R (sometimes referred to as a local control module or control communication module) and forwarding table(s) 434A-R, such that a given virtual network element (e.g., 430A) includes the control communication and configuration module (e.g., 432A), a set of one or more forwarding table(s) (e.g., 434A), and that portion of the networking hardware 410 that executes the virtual network element (e.g., 430A).
  • a control communication and configuration module 432A-R sometimes referred to as a local control module or control communication module
  • forwarding table(s) 434A-R such that a given virtual network element (e.g., 430A) includes the control communication and configuration module (e.g., 432A), a set of one or more forwarding table(s) (e.g., 434A), and that portion of the networking hardware 410 that
  • the special-purpose network device 402 is often physically and/or logically considered to include: 1) a ND control plane 424 (sometimes referred to as a control plane) comprising the processor(s) 412 that execute the control communication and configuration module(s) 432A-R; and 2) a ND forwarding plane 426 (sometimes referred to as a forwarding plane, a data plane, or a media plane) comprising the forwarding resource(s) 414 that utilize the forwarding table(s) 434A-R and the physical NIs 416.
  • a ND control plane 424 (sometimes referred to as a control plane) comprising the processor(s) 412 that execute the control communication and configuration module(s) 432A-R
  • a ND forwarding plane 426 sometimes referred to as a forwarding plane, a data plane, or a media plane
  • the forwarding resource(s) 414 that utilize the forwarding table(s) 434A-R and the physical NIs 416.
  • the ND control plane 424 (the processor(s) 412 executing the control communication and configuration module(s) 432A-R) is typically responsible for participating in controlling how data (e.g., packets) is to be routed (e.g., the next hop for the data and the outgoing physical NI for that data) and storing that routing information in the forwarding table(s) 434A-R, and the ND forwarding plane 426 is responsible for receiving that data on the physical NIs 416 and forwarding that data out the appropriate ones of the physical NIs 416 based on the forwarding table(s) 434A-R.
  • data e.g., packets
  • the ND forwarding plane 426 is responsible for receiving that data on the physical NIs 416 and forwarding that data out the appropriate ones of the physical NIs 416 based on the forwarding table(s) 434A-R.
  • Figure 4B illustrates an exemplary way to implement the special-purpose network device 402 according to some embodiments of the invention.
  • Figure 4B shows a special-purpose network device including cards 438 (typically hot pluggable). While in some embodiments the cards 438 are of two types (one or more that operate as the ND forwarding plane 426 (sometimes called line cards), and one or more that operate to implement the ND control plane 424 (sometimes called control cards)), alternative embodiments may combine functionality onto a single card and/or include additional card types (e g., one additional type of card is called a service card, resource card, or multi-application card).
  • additional card types e g., one additional type of card is called a service card, resource card, or multi-application card.
  • a service card can provide specialized processing (e.g., Layer 4 to Layer 7 services (e.g., firewall, Internet Protocol Security (IPsec), Secure Sockets Layer (SSL) / Transport Layer Security (TLS), Intrusion Detection System (IDS), peer-to-peer (P2P), Voice over IP (VoIP) Session Border Controller, Mobile Wireless Gateways (Gateway General Packet Radio Service (GPRS) Support Node (GGSN), Evolved Packet Core (EPC) Gateway)).
  • Layer 4 to Layer 7 services e.g., firewall, Internet Protocol Security (IPsec), Secure Sockets Layer (SSL) / Transport Layer Security (TLS), Intrusion Detection System (IDS), peer-to-peer (P2P), Voice over IP (VoIP) Session Border Controller, Mobile Wireless Gateways (Gateway General Packet Radio Service (GPRS) Support Node (GGSN), Evolved Packet Core (EPC) Gateway)
  • GPRS General Pack
  • the general-purpose network device 404 includes hardware 440 comprising a set of one or more processor(s) 442 (which are often COTS processors) and physical NIs 446, as well as non-transitory machine-readable storage media 448 having stored therein software 450.
  • the processor(s) 442 execute the software 450 to instantiate one or more sets of one or more applications 464A-R. While one embodiment does not implement virtualization, alternative embodiments may use different forms of virtualization.
  • the virtualization layer 454 represents the kernel of an operating system (or a shim executing on a base operating system) that allows for the creation of multiple instances 462A-R called software containers that may each be used to execute one (or more) of the sets of applications 464A-R; where the multiple software containers (also called virtualization engines, virtual private servers, or jails) are user spaces (typically a virtual memory space) that are separate from each other and separate from the kernel space in which the operating system is run; and where the set of applications running in a given user space, unless explicitly allowed, cannot access the memory of the other processes.
  • the multiple software containers also called virtualization engines, virtual private servers, or jails
  • user spaces typically a virtual memory space
  • the virtualization layer 454 represents a hypervisor (sometimes referred to as a virtual machine monitor (VMM)) or a hypervisor executing on top of a host operating system, and each of the sets of applications 464A-R is run on top of a guest operating system within an instance 462A-R called a virtual machine (which may in some cases be considered a tightly isolated form of software container) that is run on top of the hypervisor - the guest operating system and application may not know they are running on a virtual machine as opposed to running on a “bare metal” host electronic device, or through para-virtualization the operating system and/or application may be aware of the presence of virtualization for optimization purposes.
  • a hypervisor sometimes referred to as a virtual machine monitor (VMM)
  • VMM virtual machine monitor
  • one, some or all of the applications are implemented as unikemel(s), which can be generated by compiling directly with an application only a limited set of libraries (e.g., from a library operating system (LibOS) including drivers/libraries of OS services) that provide the particular OS services needed by the application.
  • libraries e.g., from a library operating system (LibOS) including drivers/libraries of OS services
  • unikernel can be implemented to run directly on hardware 440, directly on a hypervisor (in which case the unikernel is sometimes described as running within a LibOS virtual machine), or in a software container
  • embodiments can be implemented fully with unikemels running directly on a hypervisor represented by virtualization layer 454, unikemels running within software containers represented by instances 462A-R, or as a combination of unikemels and the above-described techniques (e.g., unikemels and virtual machines both run directly on a hypervisor, unikemels and sets of applications that are run in different software containers).
  • the virtual network element(s) 460A-R perform similar functionality to the virtual network element(s) 430A-R - e.g., similar to the control communication and configuration module(s) 432A and forwarding table(s) 434A (this virtualization of the hardware 440 is sometimes referred to as network function virtualization (NFV)).
  • NFV network function virtualization
  • NTV may be used to consolidate many network equipment types onto industry standard high volume server hardware, physical switches, and physical storage, which could be located in Data centers, NDs, and customer premise equipment (CPE).
  • each instance 462A-R corresponding to one VNE 460A-R
  • alternative embodiments may implement this correspondence at a finer level granularity (e.g., line card virtual machines virtualize line cards, control card virtual machine virtualize control cards, etc.); it should be understood that the techniques described herein with reference to a correspondence of instances 462A-R to VNEs also apply to embodiments where such a finer level of granularity and/or unikemels are used.
  • the virtualization layer 454 includes a virtual switch that provides similar forwarding services as a physical Ethernet switch. Specifically, this virtual switch forwards traffic between instances 462A-R and the physical NI(s) 446, as well as optionally between the instances 462A-R; in addition, this virtual switch may enforce network isolation between the VNEs 460A-R that by policy are not permitted to communicate with each other (e.g., by honoring virtual local area networks (VLANs)).
  • the third exemplary ND implementation in Figure 4A is a hybrid network device 406, which includes both custom ASICs/special-purpose OS and COTS processors/standard OS in a single ND or a single card within an ND.
  • a platform VM i.e., a VM that that implements the functionality of the special-purpose network device 402 could provide for para-virtualization to the networking hardware present in the hybrid network device 406.
  • NE network element
  • each of the VNEs receives data on the physical NIs (e.g., 416, 446) and forwards that data out the appropriate ones of the physical NIs (e.g., 416, 446).
  • the physical NIs e.g., 416, 446
  • a VNE implementing IP router functionality forwards IP packets on the basis of some of the IP header information in the IP packet; where IP header information includes source IP address, destination IP address, source port, destination port (where “source port” and “destination port” refer herein to protocol ports, as opposed to physical ports of a ND), transport protocol (e.g., user datagram protocol (UDP), Transmission Control Protocol (TCP), and differentiated services code point (DSCP) values.
  • transport protocol e.g., user datagram protocol (UDP), Transmission Control Protocol (TCP), and differentiated services code point (DSCP) values.
  • UDP user datagram protocol
  • TCP Transmission Control Protocol
  • DSCP differentiated services code point
  • Figure 4C illustrates various exemplary ways in which VNEs may be coupled according to some embodiments of the invention.
  • Figure 4C shows VNEs 470A.1-470A.P (and optionally VNEs 470A.Q-470A.R) implemented in ND 400A and VNE 470H.1 in ND 400H.
  • VNEs 470A.1-P are separate from each other in the sense that they can receive packets from outside ND 400A and forward packets outside of ND 400 A; VNE 470A.1 is coupled with VNE 470H.1, and thus they communicate packets between their respective NDs; VNE 470A.2-470A.3 may optionally forward packets between themselves without forwarding them outside of the ND 400A; and VNE 470A.P may optionally be the first in a chain of VNEs that includes VNE 470A.Q followed by VNE 470A.R (this is sometimes referred to as dynamic service chaining, where each of the VNEs in the series of VNEs provides a different service - e.g., one or more layer 4-7 network services). While Figure 4C illustrates various exemplary relationships between the VNEs, alternative embodiments may support other relationships (e.g., more/fewer VNEs, more/fewer dynamic service chains, multiple different dynamic service chains with some common VNEs and some different VNE
  • the NDs of Figure 4A may form part of the Internet or a private network; and other electronic devices (not shown; such as end user devices including workstations, laptops, netbooks, tablets, palm tops, mobile phones, smartphones, phablets, multimedia phones, Voice Over Internet Protocol (VOIP) phones, terminals, portable media players, GPS units, wearable devices, gaming systems, set-top boxes, Internet enabled household appliances) may be coupled to the network (directly or through other networks such as access networks) to communicate over the network (e.g., the Internet or virtual private networks (VPNs) overlaid on (e g., tunneled through) the Internet) with each other (directly or through servers) and/or access content and/or services.
  • end user devices including workstations, laptops, netbooks, tablets, palm tops, mobile phones, smartphones, phablets, multimedia phones, Voice Over Internet Protocol (VOIP) phones, terminals, portable media players, GPS units, wearable devices, gaming systems, set-top boxes, Internet enabled household appliances
  • VOIP
  • Such content and/or services are typically provided by one or more servers (not shown) belonging to a service/content provider or one or more end user devices (not shown) participating in a peer-to-peer (P2P) service, and may include, for example, public webpages (e.g., free content, store fronts, search services), private webpages (e.g., username/password accessed webpages providing email services), and/or corporate networks over VPNs.
  • end user devices may be coupled (e.g., through customer premise equipment coupled to an access network (wired or wirelessly)) to edge NDs, which are coupled (e.g., through one or more core NDs) to other edge NDs, which are coupled to electronic devices acting as servers.
  • one or more of the electronic devices operating as the NDs in Figure 4A may also host one or more such servers (e.g., in the case of the general purpose network device 404, one or more of the software instances 462A-R may operate as servers; the same would be true for the hybrid network device 406; in the case of the special-purpose network device 402, one or more such servers could also be run on a virtualization layer executed by the processor(s) 412); in which case the servers are said to be co-located with the VNEs of that ND.
  • the servers are said to be co-located with the VNEs of that ND.
  • a virtual network is a logical abstraction of a physical network (such as that in Figure 4A) that provides network services (e.g., L2 and/or L3 services).
  • a virtual network can be implemented as an overlay network (sometimes referred to as a network virtualization overlay) that provides network services (e.g., layer 2 (L2, data link layer) and/or layer 3 (L3, network layer) services) over an underlay network (e.g., an L3 network, such as an Internet Protocol (IP) network that uses tunnels (e.g., generic routing encapsulation (GRE), layer 2 tunneling protocol (L2TP), IPSec) to create the overlay network).
  • IP Internet Protocol
  • a network virtualization edge sits at the edge of the underlay network and participates in implementing the network virtualization; the network-facing side of the NVE uses the underlay network to tunnel frames to and from other NVEs; the outward-facing side of the NVE sends and receives data to and from systems outside the network.
  • a virtual network instance is a specific instance of a virtual network on a NVE (e.g., a NE/VNE on an ND, a part of a NE/VNE on a ND where that NE/VNE is divided into multiple VNEs through emulation); one or more VNIs can be instantiated on an NVE (e.g., as different VNEs on an ND).
  • a virtual access point is a logical connection point on the NVE for connecting external systems to a virtual network; a VAP can be physical or virtual ports identified through logical interface identifiers (e.g., a VLAN ID).
  • Examples of network services include: 1) an Ethernet LAN emulation service (an Ethernet-based multipoint service similar to an Internet Engineering Task Force (IETF) Multiprotocol Label Switching (MPLS) or Ethernet VPN (EVPN) service) in which external systems are interconnected across the network by a LAN environment over the underlay network (e.g., an NVE provides separate L2 VNIs (virtual switching instances) for different such virtual networks, and L3 (e.g., IP/MPLS) tunneling encapsulation across the underlay network); and 2) a virtualized IP forwarding service (similar to IETF IP VPN (e.g., Border Gateway Protocol (BGP)/MPLS IPVPN) from a service definition perspective) in which external systems are interconnected across the network by an L3 environment over the underlay network (e.g., an NVE provides separate L3 VNIs (forwarding and routing instances) for different such virtual networks, and L3 (e.g., IP/MPLS) tunneling encapsulation across the underlay network)
  • Network services may also include quality of service capabilities (e.g., traffic classification marking, traffic conditioning and scheduling), security capabilities (e.g., filters to protect customer premises from network originated attacks, to avoid malformed route announcements), and management capabilities (e.g., full detection and processing).
  • quality of service capabilities e.g., traffic classification marking, traffic conditioning and scheduling
  • security capabilities e.g., filters to protect customer premises from network originated attacks, to avoid malformed route announcements
  • management capabilities e.g., full detection and processing
  • Figure 4D illustrates a network with a single network element on each of the NDs of Figure 4A, and within this straight forward approach contrasts a traditional distributed approach (commonly used by traditional routers) with a centralized approach for maintaining reachability and forwarding information (also called network control), according to some embodiments of the invention.
  • Figure 4D illustrates network elements (NEs) 470A-H with the same connectivity as the NDs 400 A-H of Figure 4 A.
  • Figure 4D illustrates that the distributed approach 472 distributes responsibility for generating the reachability and forwarding information across the NEs 470A-H; in other words, the process of neighbor discovery and topology discovery is distributed.
  • the control communication and configuration module(s) 432A-R of the ND control plane 424 typically include a reachability and forwarding information module to implement one or more routing protocols (e.g., an exterior gateway protocol such as Border Gateway Protocol (BGP), Interior Gateway Protocol(s) (IGP) (e.g., Open Shortest Path First (OSPF), Intermediate System to Intermediate System (IS-IS), Routing Information Protocol (RIP), Label Distribution Protocol (LDP), Resource Reservation Protocol (RSVP) (including RSVP-Traffic Engineering (TE): Extensions to RSVP for LSP Tunnels and Generalized Multi -Protocol Label Switching (GMPLS) Signaling RSVP-TE)) that communicate with other NEs to exchange routes, and then selects those routes based on one or more routing metrics.
  • Border Gateway Protocol BGP
  • IGP Interior Gateway Protocol
  • OSPF Open Shortest Path First
  • IS-IS Intermediate System to Intermediate System
  • RIP Routing Information Protocol
  • LDP Label Distribution Protocol
  • RSVP Resource Reservation Protocol
  • TE Extensions to RSVP for LSP Tunnels and
  • the NEs 470A-H e.g., the processor(s) 412 executing the control communication and configuration module(s) 432A-R
  • Routes and adjacencies are stored in one or more routing structures (e.g., Routing Information Base (RIB), Label Information Base (LIB), one or more adjacency structures) on the ND control plane 424
  • the ND control plane 424 programs the ND forwarding plane 426 with information (e.g., adjacency and route information) based on the routing structure(s). For example, the ND control plane 424 programs the adjacency and route information into one or more forwarding table(s) 434A-R (e.g., Forwarding Information Base (FIB), Label Forwarding Information Base (LFIB), and one or more adjacency structures) on the ND forwarding plane 426.
  • FIB Forwarding Information Base
  • LFIB Label Forwarding Information Base
  • the ND can store one or more bridging tables that are used to forward data based on the layer 2 information in that data. While the above example uses the special-purpose network device 402, the same distributed approach 472 can be implemented on the general-purpose network device 404 and the hybrid network device 406. [0087] Figure 4D illustrates that a centralized approach 474 (also known as software defined networking (SDN)) that decouples the system that makes decisions about where traffic is sent from the underlying systems that forwards traffic to the selected destination.
  • SDN software defined networking
  • the illustrated centralized approach 474 has the responsibility for the generation of reachability and forwarding information in a centralized control plane 476 (sometimes referred to as a SDN control module, controller, network controller, OpenFlow controller, SDN controller, control plane node, network virtualization authority, or management control entity), and thus the process of neighbor discovery and topology discovery is centralized.
  • the centralized control plane 476 has a south bound interface 482 with a data plane 480 (sometime referred to the infrastructure layer, network forwarding plane, or forwarding plane (which should not be confused with a ND forwarding plane)) that includes the NEs 470A-H (sometimes referred to as switches, forwarding elements, data plane elements, or nodes).
  • the centralized control plane 476 includes a network controller 478, which includes a centralized reachability and forwarding information module 479 that determines the reachability within the network and distributes the forwarding information to the NEs 470A-H of the data plane 480 over the south bound interface 482 (which may use the OpenFlow protocol).
  • the network intelligence is centralized in the centralized control plane 476 executing on electronic devices that are typically separate from the NDs.
  • each of the control communication and configuration module(s) 432A-R of the ND control plane 424 typically include a control agent that provides the VNE side of the south bound interface 482.
  • the ND control plane 424 (the processor(s) 412 executing the control communication and configuration module(s) 432A-R) performs its responsibility for participating in controlling how data (e g., packets) is to be routed (e g., the next hop for the data and the outgoing physical NT for that data) through the control agent communicating with the centralized control plane 476 to receive the forwarding information (and in some cases, the reachability information) from the centralized reachability and forwarding information module 479 (it should be understood that in some embodiments of the invention, the control communication and configuration module(s) 432A-R, in addition to communicating with the centralized control plane 476, may also play some role in determining reachability and/or calculating forwarding information - albeit less so than in the case of a distributed approach; such embodiments are generally considered to fall under the centralized approach 474, but may also be considered a hybrid approach).
  • data e g., packets
  • the control agent communicating with the centralized control plane 476 to receive the forwarding
  • the same centralized approach 474 can be implemented with the general purpose network device 404 (e.g., each of the VNE 460A-R performs its responsibility for controlling how data (e.g., packets) is to be routed (e.g., the next hop for the data and the outgoing physical NI for that data) by communicating with the centralized control plane 476 to receive the forwarding information (and in some cases, the reachability information) from the centralized reachability and forwarding information module 479; it should be understood that in some embodiments of the invention, the VNEs 460A-R, in addition to communicating with the centralized control plane 476, may also play some role in determining reachability and/or calculating forwarding information - albeit less so than in the case of a distributed approach) and the hybrid network device 406.
  • the general purpose network device 404 e.g., each of the VNE 460A-R performs its responsibility for controlling how data (e.g., packets) is to be routed (e.g., the next hop for
  • NFV is able to support SDN by providing an infrastructure upon which the SDN software can be run, and NFV and SDN both aim to make use of commodity server hardware and physical switches.
  • Figure 4D also shows that the centralized control plane 476 has a north bound interface 484 to an application layer 486, in which resides application(s) 488.
  • the centralized control plane 476 has the ability to form virtual networks 492 (sometimes referred to as a logical forwarding plane, network services, or overlay networks (with the NEs 470A-H of the data plane 480 being the underlay network)) for the application(s) 488.
  • virtual networks 492 sometimes referred to as a logical forwarding plane, network services, or overlay networks (with the NEs 470A-H of the data plane 480 being the underlay network)
  • the centralized control plane 476 maintains a global view of all NDs and configured NEs/VNEs, and it maps the virtual networks to the underlying NDs efficiently (including maintaining these mappings as the physical network changes either through hardware (ND, link, or ND component) failure, addition, or removal).
  • Figure 4D shows the distributed approach 472 separate from the centralized approach 474
  • the effort of network control may be distributed differently or the two combined in certain embodiments of the invention.
  • embodiments may generally use the centralized approach (SDN) 474, but have certain functions delegated to the NEs (e.g., the distributed approach may be used to implement one or more of fault monitoring, performance monitoring, protection switching, and primitives for neighbor and/or topology discovery); or 2) embodiments of the invention may perform neighbor discovery and topology discovery via both the centralized control plane and the distributed protocols, and the results compared to raise exceptions where they do not agree.
  • SDN centralized approach
  • Such embodiments are generally considered to fall under the centralized approach 474, but may also be considered a hybrid approach.
  • Figure 4D illustrates the simple case where each of the NDs 400A-H implements a single NE 470A-H
  • the network control approaches described with reference to Figure 4D also work for networks where one or more of the NDs 400A-H implement multiple VNEs (e.g., VNEs 430A-R, VNEs 460A-R, those in the hybrid network device 406).
  • the network controller 478 may also emulate the implementation of multiple VNEs in a single ND.
  • the network controller 478 may present the implementation of a VNE/NE in a single ND as multiple VNEs in the virtual networks 492 (all in the same one of the virtual network(s) 492, each in different ones of the virtual network(s)
  • the network controller 478 may cause an ND to implement a single VNE (a NE) in the underlay network, and then logically divide up the resources of that NE within the centralized control plane 476 to present different VNEs in the virtual network(s) 492 (where these different VNEs in the overlay networks are sharing the resources of the single VNE/NE implementation on the ND in the underlay network).
  • a single VNE a NE
  • the network controller 478 may cause an ND to implement a single VNE (a NE) in the underlay network, and then logically divide up the resources of that NE within the centralized control plane 476 to present different VNEs in the virtual network(s) 492 (where these different VNEs in the overlay networks are sharing the resources of the single VNE/NE implementation on the ND in the underlay network).
  • Figures 4E and 4F respectively illustrate exemplary abstractions of NEs and VNEs that the network controller 478 may present as part of different ones of the virtual networks 492.
  • Figure 4E illustrates the simple case of where each of the NDs 400A-H implements a single NE 470A-H (see Figure 4D), but the centralized control plane 476 has abstracted multiple of the NEs in different NDs (the NEs 470A-C and G-H) into (to represent) a single NE 4701 in one of the virtual network(s) 492 of Figure 4D, according to some embodiments of the invention.
  • Figure 4E shows that in this virtual network, the NE 4701 is coupled to NE 470D and 470F, which are both still coupled to NE 470E.
  • Figure 4F illustrates a case where multiple VNEs (VNE 470A.1 and VNE 470H.1) are implemented on different NDs (ND 400A and ND 400H) and are coupled to each other, and where the centralized control plane 476 has abstracted these multiple VNEs such that they appear as a single VNE 470T within one of the virtual networks 492 of Figure 4D, according to some embodiments of the invention.
  • the abstraction of a NE or VNE can span multiple NDs.
  • the electronic device(s) running the centralized control plane 476 may be implemented a variety of ways (e.g., a special purpose device, a general-purpose (e.g., COTS) device, or hybrid device). These electronic device(s) would similarly include processor(s), a set or one or more physical NIs, and a non-transitory machine-readable storage medium having stored thereon the centralized control plane software.
  • Figure 5 illustrates, a general purpose control plane device 504 including hardware 540 comprising a set of one or more processor(s) 542 (which are often COTS processors) and physical NIs 546, as well as non-transitory machine readable storage media 548 having stored therein centralized control plane (CCP) software 550.
  • processor(s) 542 which are often COTS processors
  • NIs 546 physical NIs 546
  • CCP centralized control plane
  • the processor(s) 542 typically execute software to instantiate a virtualization layer 554 (e.g., in one embodiment the virtualization layer 554 represents the kernel of an operating system (or a shim executing on a base operating system) that allows for the creation of multiple instances 562A-R called software containers (representing separate user spaces and also called virtualization engines, virtual private servers, or jails) that may each be used to execute a set of one or more applications; in another embodiment the virtualization layer 554 represents a hypervisor (sometimes referred to as a virtual machine monitor (VMM)) or a hypervisor executing on top of a host operating system, and an application is run on top of a guest operating system within an instance 562A-R called a virtual machine (which in some cases may be considered a tightly isolated form of software container) that is run by the hypervisor ; in another embodiment, an application is implemented as a unikernel, which can be generated by compiling directly with an application only a
  • VMM virtual machine monitor
  • an instance of the CCP software 550 (illustrated as CCP instance 576A) is executed (e.g., within the instance 562A) on the virtualization layer 554.
  • the CCP instance 576A is executed, as a unikemel or on top of a host operating system, on the “bare metal” general purpose control plane device 504.
  • the instantiation of the CCP instance 576A, as well as the virtualization layer 554 and instances 562A-R if implemented, are collectively referred to as software instance(s) 552.
  • the CCP instance 576A includes a network controller instance 578.
  • the network controller instance 578 includes a centralized reachability and forwarding information module instance 579 (which is a middleware layer providing the context of the network controller 478 to the operating system and communicating with the various Es), and an CCP application layer 580 (sometimes referred to as an application layer) over the middleware layer (providing the intelligence required for various network operations such as protocols, network situational awareness, and user - interfaces).
  • this CCP application layer 580 within the centralized control plane 476 works with virtual network view(s) (logical view(s) of the network) and the middleware layer provides the conversion from the virtual networks to the physical view.
  • the centralized control plane 476 transmits relevant messages to the data plane 480 based on CCP application layer 580 calculations and middleware layer mapping for each flow.
  • a flow may be defined as a set of packets whose headers match a given pattern of bits; in this sense, traditional IP forwarding is also flow-based forwarding where the flows are defined by the destination IP address for example; however, in other implementations, the given pattern of bits used for a flow definition may include more fields (e.g., 10 or more) in the packet headers.
  • Different NDs/NEs/YNEs of the data plane 480 may receive different messages, and thus different forwarding information.
  • the data plane 480 processes these messages and programs the appropriate flow information and corresponding actions in the forwarding tables (sometime referred to as flow tables) of the appropriate NE/V Es, and then the NEs/VNEs map incoming packets to flows represented in the forwarding tables and forward packets based on the matches in the forwarding tables.
  • Standards such as OpenFlow define the protocols used for the messages, as well as a model for processing the packets.
  • the model for processing packets includes header parsing, packet classification, and making forwarding decisions. Header parsing describes how to interpret a packet based upon a well-known set of protocols. Some protocol fields are used to build a match structure (or key) that will be used in packet classification (e.g., a first key field could be a source media access control (MAC) address, and a second key field could be a destination MAC address).
  • MAC media access control
  • Packet classification involves executing a lookup in memory to classify the packet by determining which entry (also referred to as a forwarding table entry or flow entry) in the forwarding tables best matches the packet based upon the match structure, or key, of the forwarding table entries. It is possible that many flows represented in the forwarding table entries can correspond/match to a packet; in this case the system is typically configured to determine one forwarding table entry from the many according to a defined scheme (e.g., selecting a first forwarding table entry that is matched).
  • Forwarding table entries include both a specific set of match criteria (a set of values or wildcards, or an indication of what portions of a packet should be compared to a particular value/values/wildcards, as defined by the matching capabilities for specific fields in the packet header, or for some other packet content), and a set of one or more actions for the data plane to take on receiving a matching packet. For example, an action may be to push a header onto the packet, for the packet using a particular port, flood the packet, or simply drop the packet.
  • TCP transmission control protocol
  • an unknown packet for example, a “missed packet” or a “match- miss” as used in OpenFlow parlance
  • the packet (or a subset of the packet header and content) is typically forwarded to the centralized control plane 476.
  • the centralized control plane 476 will then program forwarding table entries into the data plane 480 to accommodate packets belonging to the flow of the unknown packet. Once a specific forwarding table entry has been programmed into the data plane 480 by the centralized control plane 476, the next packet with matching credentials will match that forwarding table entry and take the set of actions associated with that matched entry.
  • a network interface may be physical or virtual; and in the context of IP, an interface address is an IP address assigned to a NI, be it a physical NI or virtual NI.
  • a virtual NI may be associated with a physical NI, with another virtual interface, or stand on its own (e.g., a loopback interface, a point-to-point protocol interface).
  • a NI physical or virtual
  • a loopback interface (and its loopback address) is a specific type of virtual NI (and IP address) of a NE/VNE (physical or virtual) often used for management purposes; where such an IP address is referred to as the nodal loopback address.
  • IP addresses of that ND are referred to as IP addresses of that ND; at a more granular level, the IP address(es) assigned to NI(s) assigned to a NE/VNE implemented on a ND can be referred to as IP addresses of that NE/VNE.

Abstract

Methods and systems in a network device for efficient I/O transfer from a network device to an application are presented. In one embodiment, information regarding metadata is received. The metadata is to be used by an application for processing packets received through the network interface of network interface system. A metadata data structure is determined based on the information. The metadata data structure is customized for the application. The application is updated with the metadata data structure, and the network interface system is notified with of the metadata data structure. The notification causes the network interface system to transfer metadata to the application according to the metadata data structure.

Description

METHODS AND SYSTEMS FOR EFFICIENT METADATA AND DATA DELIVERY BETWEEN A NETWORK INTERFACE AND APPLICATIONS
TECHNICAL FIELD
[0001] Embodiments of the invention relate to the field of packet networking; and more specifically, to the efficient metadata and data delivery between a network interface and applications.
BACKGROUND
[0002] A network device (ND) is an electronic device that communicatively interconnects other electronic devices on the network (e.g., other network devices, end-user devices). Some network devices are “multiple services network devices” that provide support for multiple networking functions (e.g., routing, bridging, switching, Layer 2 aggregation, session border control, Quality of Service, and/or subscriber management), and/or provide support for multiple application services (e.g., data, voice, and video).
[0003] A network device receives input data, processes the data, and outputs the data following its processing. For example, a network device may receive network packets, and output network packets following their processing. A network device includes one or more processing units on which code is executed for processing the input data. The processing units are coupled with a network interface. A network interface (NI) is an electronic device operative to establish network connections (to transmit and/or receive data using propagating signals) with other electronic devices. For example, a NI receives the data from other network devices, transfers the data to the processing unit(s) for processing, and outputs the processed data towards other network devices.
[0004] Applications, such as virtualized network function (VNF), running on the network device receive data and metadata and/or annotations from the NI. In some examples, VNF can be composed using modular packet processing frameworks such as Click, FastClick, Vector Packet Processor (VPP), and Berkeley Extensible Software Switch (BESS). Applications typically use kernel-space and/or user-space libraries to interact with a NI. These libraries allocate memory from the network device’s main memory (e.g., DRAM) during their initialization phase (known as buffers) and then the NI driver passes the address of the allocated memory /buffers to the NI. When the NI receives packets, it transfers the packets to the location of the buffers (e.g., through a Direct Memory Access or DMA). The applications operate on these buffers and follow a similar procedure if they need to send the processed data back to the NI.
SUMMARY
[0005] The embodiments described herein present a solution for efficient input/output transfer in network devices. The solution integrates to network and electronic devices the ability to efficiently transfer packets and metadata from a network interface to an application. The solution advantageously optimizes the amount/size of metadata for Input/Output (I/O) data used by an application consequently reducing the application's footprint. The solution prevents extra operations for making I/O data and the metadata compatible with the application. The solution advantageously enables the application to receive the I/O data, and the metadata with an efficient format and size customized for data processing by the application.
[0006] One general aspect includes a method in a network device. The method includes receiving information regarding metadata to be used by an application for processing packets received through a network interface of a network interface system; determining, based on the information, a metadata data structure that is customized for the application; updating the application with the metadata data structure, and notifying the network interface system with of the metadata data structure, where the notification causes the network interface system to transfer the metadata to the application according to the metadata data structure.
[0007] One general aspect includes a network device. The network device includes a non- transitory machine-readable storage medium that provides instructions that, if executed by a processor, will cause the network device to perform operations including: receiving information regarding metadata to be used by an application for processing packets received through a network interface of a network interface system; determining, based on the information, a metadata data structure that is customized for the application; updating the application with the metadata data structure; and notifying the network interface system with of the metadata data structure, where the notification causes the network interface system to transfer the metadata to the application according to the metadata data structure.
[0008] One general aspect includes a non-transitory machine-readable storage medium may include computer program code which when executed by a processor of a network device carries out operations. The operations includes receiving information regarding metadata to be used by an application for processing packets received through a network interface of a network interface system; determining, based on the information, a metadata data structure that is customized for the application; updating the application with the metadata data structure; and notifying the network interface system with of the metadata data structure, where the notification causes the network interface system to transfer the metadata to the application according to the metadata data structure.
[0009] One general aspect includes a method in a network interface. The method includes receiving information on a metadata data structure for an application that is to process packets received through the network interface; receiving a packet at the network interface; adding the packet to a receive queue of the network interface; determining, based on the information, whether customized metadata is to be generated in the network interface for the packet; and responsive to determining that the customized metadata is to be generated in the network interface, determining, based on the information, the customized metadata for the packet, and transferring the customized metadata and the packet to the application according to the metadata data structure.
[0010] One general aspect includes a network interface. The network interface includes a non- transitory machine-readable storage medium that provides instructions that, if executed by a processor, will cause the network interface to perform operations including, receiving information on a metadata data structure for an application that is to process packets received through the network interface; receiving a packet at the network interface; adding the packet to a receive queue of the network interface; determining, based on the information, whether customized metadata is to be generated in the network interface for the packet; and responsive to determining that the customized metadata is to be generated in the network interface, determining, based on the information, the customized metadata for the packet, and transferring the customized metadata and the packet to the application according to the metadata data structure.
[0011] One general aspect includes a non-transitory machine-readable storage medium may include computer program code which when executed by a processor of a network interface carries out operations. The operations includes receiving information on a metadata data structure for an application that is to process packets received through the network interface; receiving a packet at the network interface; adding the packet to a receive queue of the network interface; determining, based on the information, whether customized metadata is to be generated in the network interface for the packet; and responsive to determining that the customized metadata is to be generated in the network interface, determining, based on the information, the customized metadata for the packet, and transferring the customized metadata and the packet to the application according to the metadata data structure. BRIEF DESCRIPTION OF THE DRAWINGS
[0012] The invention may best be understood by referring to the following description and accompanying drawings that are used to illustrate embodiments of the invention. In the drawings:
[0013] Figure 1 A illustrates a block diagram of a system for efficient metadata transfer to an application, in accordance with some embodiments.
[0014] Figure IB illustrates a block diagram of an exemplary NI that includes a metadata manager 190, in accordance with some embodiments.
[0015] Figure 2A illustrates a flow diagram of exemplary operations that can be performed for efficient metadata transfer between a network interface and applications, in accordance with some embodiments.
[0016] Figure 2B illustrates a flow diagram of exemplary operations 210 that can be performed for analyzing information related to metadata for an application, in accordance with some embodiments.
[0017] Figure 2C illustrates a flow diagram of exemplary operations that can be performed when a packet is received in a network interface, in accordance with some embodiments.
[0018] Figure 3 illustrates a flow diagram of exemplary operations that can be performed when a packet is received in a network interface that includes a metadata manager 190, in accordance with some embodiments.
[0019] Figure 4A illustrates connectivity between network devices (NDs) within an exemplary network, as well as three exemplary implementations of the NDs, according to some embodiments of the invention.
[0020] Figure 4B illustrates an exemplary way to implement a special-purpose network device according to some embodiments of the invention.
[0021] Figure 4C illustrates various exemplary ways in which virtual network elements (VNEs) may be coupled according to some embodiments of the invention.
[0022] Figure 4D illustrates a network with a single network element (NE) on each of the NDs, and within this straight forward approach contrasts a traditional distributed approach (commonly used by traditional routers) with a centralized approach for maintaining reachability and forwarding information (also called network control), according to some embodiments of the invention.
[0023] Figure 4E illustrates the simple case of where each of the NDs implements a single NE, but a centralized control plane has abstracted multiple of the NEs in different NDs into (to represent) a single NE in one of the virtual network(s), according to some embodiments of the invention. [0024] Figure 4F illustrates a case where multiple VNEs are implemented on different NDs and are coupled to each other, and where a centralized control plane has abstracted these multiple VNEs such that they appear as a single VNE within one of the virtual networks, according to some embodiments of the invention.
[0025] Figure 5 illustrates a general-purpose control plane device with centralized control plane (CCP) software 550), according to some embodiments of the invention.
DETAILED DESCRIPTION
[0026] The following description describes methods and systems for efficient metadata and data delivery between input/output devices and software-based packet processing applications.
In the following description, numerous specific details such as logic implementations, opcodes, means to specify operands, resource partitioning/sharing/duplication implementations, types and interrelationships of system components, and logic partitioning/integration choices are set forth in order to provide a more thorough understanding of the present invention. It will be appreciated, however, by one skilled in the art that the invention may be practiced without such specific details. In other instances, control structures, gate level circuits and full software instruction sequences have not been shown in detail in order not to obscure the invention. Those of ordinary skill in the art, with the included descriptions, will be able to implement appropriate functionality without undue experimentation.
[0027] References in the specification to “one embodiment,” “an embodiment,” “an example embodiment,” etc., indicate that the embodiment described may include a particular feature, structure, or characteristic, but every embodiment may not necessarily include the particular feature, structure, or characteristic. Moreover, such phrases are not necessarily referring to the same embodiment. Further, when a particular feature, structure, or characteristic is described in connection with an embodiment, it is submitted that it is within the knowledge of one skilled in the art to affect such feature, structure, or characteristic in connection with other embodiments whether or not explicitly described.
[0028] Bracketed text and blocks with dashed borders (e.g., large dashes, small dashes, dot- dash, and dots) may be used herein to illustrate optional operations that add additional features to embodiments of the invention. However, such notation should not be taken to mean that these are the only options or optional operations, and/or that blocks with solid borders are not optional in certain embodiments of the invention.
[0029] In the following description and claims, the terms “coupled” and “connected,” along with their derivatives, may be used. It should be understood that these terms are not intended as synonyms for each other. “Coupled” is used to indicate that two or more elements, which may or may not be in direct physical or electrical contact with each other, co-operate or interact with each other. “Connected” is used to indicate the establishment of communication between two or more elements that are coupled with each other.
[0030] Applications such as networking applications running on commodity hardware (VNF) can use additional information beyond the raw packets (i.e., bits received from the wire) to perform packet processing. In the following description, the additional information will be referred to as metadata. The metadata may include one or more fields and the size of metadata depends on the type of application. The metadata can be needed by one or more applications to operate/process the raw bits of the packets. Some fields of the metadata can be automatically generated by the NI upon receipt of the packet.
[0031] Different applications usually use common frameworks/libraries to implement their networking functionalities and obtain data and/or metadata from the NI. For instance, applications can either use (i) kernel-space interfaces/modules/libraries such as Berkeley sockets API and extended Berkeley Packet Filter (eBPF)/ eXpress Data Path (XDP) or (ii) user-space libraries such as Data Plane Development Kit (DPDK) and netmap to receive/send packets and interact with network interfaces. However, these frameworks/libraries are designed with generality in mind, which prevents them from having customized metadata for different applications. The frameworks and libraries present generic data structures for storing the metadata. Consequently, the applications need to adapt the existing generic data structures of the framework and libraries to their needs. To ensure proper functionality, the applications need to copy the metadata generated based on these frameworks to their respective application-specific data structures. Additionally, since different applications might perform different tasks at different stages, to avoid conflicts between these tasks the applications often allocate a general- purpose space in memory for handling the metadata. This space is often larger than the applications’ needs and remains mostly unused. However, the allocation of extra space reduces caches locality and the performance of the system. In addition to the unoptimized size for the metadata, the application-specific data structure used in the applications does not necessarily contain the right order for different tasks. For example, some fields of the metadata might be stored on different cache/memory lines, despite being accessed consecutively, which results in a nonoptimal cache locality and increased access latency in many cases.
[0032] In existing networking frameworks, the driver of the NI passes to the NI addresses of buffers in the main memory for storing the data and metadata for the applications. Due to proprietary design and simplicity, the NI driver often uses vendor-specific data structures for managing the metadata. These vendor-specific data structures are different and independent of the generic data structures defined by the frameworks and libraries used by the applications. Consequently, the NI driver needs to copy /convert the metadata/annotations received from the NI to the generic data structures that are used by the frameworks and libraries. Thus, in current systems, to deliver the metadata from the NI to the applications three copying/conversion operations need to be performed: (i) from NI registers/memory to NI driver specific data structures, (ii) from NIC driver data structures to the generic data structures of the framework and libraries, and (iii) from the framework and libraries’ data structures to the application- specific data structures. Thus, in these solutions data delivery from NI to applications is highly inefficient, as these solutions impose unnecessary expensive operations that reduce cache locality and require extra CPU cycles. Further, the existing solutions are unable to perform efficiently at high-speed (e.g., 100/200/400 Gbps) when packets are received every few nanoseconds. Further, using proprietary and vendor-specific data structures causes unnecessary data transfer (wasting Peripheral Component Interconnect Express (PCIe) bandwidth and introducing extra latency) between I/O devices and processors running I/O application as some of the metadata fields are never used.
[0033] The embodiments disclosed herein address the above and other deficiencies by presenting methods and systems that enable an efficient metadata delivery between input/output devices and applications. Embodiments presented herein enable a metadata data structure determiner to determine a metadata data structure that is customized/optimized for an application; and to inform the NI of the metadata data structure. Informing the NI of the metadata data structure prevents unnecessary and expensive copying/conversion operations of the metadata before the metadata gets delivered to the application. In some embodiments, the methods and systems presented herein enable an application-level analysis to optimize/minimize the size of the metadata and/or order of metadata parameters for an application. In some embodiments, methods, and systems of metadata management in a NI are described.
[0034] The embodiments herein present several advantages when compared with existing I/O delivery solutions. The embodiments herein reduce the memory size needed by applications to perform data processing (e.g., packet processing) resulting in improved cache locality. The applications seamlessly interact with NI to exchange customized data-structures for efficient TO delivery from the NI to the applications. The embodiments herein enable the applications to process packets at a faster rate since the operations to resolve formatting conflicts between different metadata data structures are avoided. Additionally, the applications receive relevant metadata from the NI without receiving unused metadata, thereby saving PCIe bandwidth and benefitting from faster I/O data transfers. The embodiments presented herein can enable a cloud provider to use fewer computing resources (e.g., servers/cores) to process applications in general and network functions in particular, which not only reduces the cost of implementations of these network functions, but also decreases energy consumption.
[0035] Methods and systems in a network device for efficient I/O transfer from a network device to an application are presented. In one embodiment, information regarding metadata is received. The metadata is to be used by an application for processing packets received through the network interface of network interface system A metadata data structure is determined based on the information. The metadata data structure is customized for the application. The application is updated with the metadata data structure, and the network interface system is notified with of the metadata data structure. The notification causes the network interface system to transfer metadata to the application according to the metadata data structure.
[0036] Methods and systems in a network device for generation of metadata of a packet customized for an application are described. In one embodiment, a network interface receives information on a metadata data structure for an application that is to process packets received through the network interface. When a packet is received at the network interface, the packet is added to a receive queue of the network interface. The network interface determines, based on the information, whether customized metadata is to be generated in the network interface for the packet; and responsive to determining that the customized metadata is to be generated in the network interface, the network interface determines, based on the information, the customized metadata for the packet, and transfers the customized metadata and the packet to the application according to the metadata data structure.
[0037] Figure 1A illustrates a block diagram of a system 100 for efficient metadata transfer to an application, in accordance with some embodiments. The system 100 includes a network device 102. The network device 102 includes a processing unit 160, a memory subsystem 164 that includes a main memory 166 and/or a cache 162, and a network interface (NI) 110. The network device 102 is operative to be coupled with one or more other network devices through the NI 110. The network device 102 further includes a network interface driver 172, optional networking libraries 174, optional packet processing framework(s) 176, one or more application(s) 178A-N, and a metadata data structure determiner (MDSD) 180.
[0038] The network interface 110 and the NI driver 172 form the NI system 120. The NI driver 172 is operative to operate or controls the NI. For example, the NI driver 172 provides an interface to NI 110, enabling operating systems, the networking libraries 174, the packet processing framework 176, and the applications 178A-N to access the NI. NI driver 172 communicates with NI 110 through a bus or a communications subsystem to which NI 110 connects. When a calling program invokes a routine in the driver, the driver issues commands to the device. The NI 110 is operative to establish network connections (to transmit and/or receive data using propagating signals) for the network device 102 with other electronic devices. For example, the NI (or the NI in combination with a processor unit of the network device executing code) may perform any formatting, coding, or translating to allow the network device to send and receive data whether over a wired and/or a wireless connection.
[0039] The processing unit 160 includes one or more processor(s) (not illustrated) that are coupled with non-transitory computer readable storage media, such as the memory subsystem 164. The memory subsystem 164 can include a cache 162 and/or a main memory 166. The cache 162 is part of the processing unit 160. During operation, the processor(s) execute code that is stored in non-transitory computer readable storage media to instantiate one or more sets of one or more applications 178A-N, optional networking libraries 174, optional packet processing framework(s) 176, and/or NI driver 172. The application(s) 178A-N process data/packets received from the NI 110. The data can be received directly from the NI 110 (through the cache 162) or from the main memory 166. In some embodiments, the NI 110 is connected to the processing unit 160 and the main memory 166 through a communication bus. In some embodiments, the NI 110 can be implemented as described with reference to Figure IB. In other embodiments, the NI 110 may include additional elements that are not illustrated in Figure IB. [0040] Figure IB illustrates a block diagram of an exemplary NI 110, in accordance with some embodiments. The NI 110 includes an input/output (I/O) controller 105 that is operative to send and receive data (e.g., packets) from an external electronic device. The I/O controller 105 may facilitate in connecting the network device to other electronic devices allowing them to communicate via wire through plugging in a cable to a physical port connected to the controller. In some embodiments, the I/O controller 105 is a Media Access Controller (MAC). In some embodiments, a physical NI may comprise radio circuitry capable of receiving data from other electronic devices over a wireless connection and/or sending data out to other devices via a wireless connection. This radio circuitry may include transmitter(s), receiver(s), and/or transceiver(s) suitable for radiofrequency communication. The radio circuitry may convert digital data into a radio signal having the appropriate parameters (e.g., frequency, timing, channel, bandwidth, etc ). The radio signal may then be transmitted via antennas to the appropriate recipient(s). The NI manager 130 is operative to decide how a packet is distributed among available receive queues, RX queues Ql-QN. These queues are used to store packets/data that are to be processed by the processing unit 160. In some embodiments, receive side scaling (RSS) mechanism can be used to distribute/schedule data to the RX queues Ql-QN. RSS is a network driver technology that enables the efficient distribution of network receive packets across multiple RX queues based on the hash of different fields of a packet. In some embodiments, NI 110 provides advanced flow-steering techniques which support advanced filtering of packets. These advanced filtering techniques enable the NI to direct the received packets to different queues based on a rule. The NI 110 also includes transmit queues, TX queues PI -PM. The TX queues PI -PM receive processed data/packets from the processing unit 160 to be output from the NI 110. The TX queues Pl-PM can receive packets/data from the main memory 166 and/or from the cache 162.
[0041] The NI 110 further includes a memory communication manager 140. The memory communication manager 140 is operative to transfer packets/data to and from the memory of a processing unit 160, e.g., main memory 166. Two mechanisms can be used for transferring data/packets from the NI 110 to the processing unit 160, 1) a first mechanism where data/packets are stored in main memory 166, 2) a second mechanisms where the packets/data are directly sent to the processing unit 160. The latter technique is sometimes referred to as direct cache access, Data Direct I/O (DDIO), or cache stashing. When an NI sends data/packets directly to the processing unit 160, the data/packets are directly stored in the cache of the processing unit 160, e.g., cache 162, or alternatively the data packets are directly sent to registers of the processing unit 160. Direct transmission of data/packets to the processing unit 160 is performed without transmission of the data/packets to the main memory 166. The data/packets are then processed by the applications 178A-N from the cache 162 or from the registers 165. When the data is stored in the main memory 166, the data is retrieved by the application 178A-N and stored in the cache before being processed by the applications or in registers.
[0042] The NI 110 includes an NI manager 130. The NI manager 130 is operative to perform multiple tasks that may include packet classification, packet filtering, and scheduling. In some embodiments, the scheduling can be performed based on the indication 194 in the information 192 regarding a metadata data structure. In some embodiments, the NI manager 130 includes the metadata manager 190. While in some embodiments, the NI is described as including the metadata manager 190 for enabling generation of metadata that is customized for applications by the NI, in other embodiments, the NI may not include the metadata manager 190. The operations of an NI including the metadata manager 190 are described in further detail below with reference to Figure 3. In some embodiments, the metadata manager 190 includes information 192 regarding a metadata data structure for an application. The information 192 can be received from the MDSD 180, the NI driver 172, and/or the applications 178A-N. The information 192 is used by the NI 110 to determine whether a customized metadata data structure is to be used for determining metadata for packets, and to determine the customized metadata when applicable. The metadata manager 190 can include information for each queue from the queues of the NI. The information 192 can include an identifier 194 of a queue of the network interface that is associated with the application 178A, an indication 195 of the metadata data structure to be used for the queue, and an optional indication 194 of additional parameters for metadata that are to be generated by the NI 110. The queue of the network interface is associated with an application 178A when the queue is configured to receive packets destined for processing by the application 178A. The indication 195 of the metadata data structure identifies the list of parameters of the metadata data structure, their format, and order. In some embodiments, the indication 195 is the metadata data structure, in other embodiments, the indication 195 identifies the location of the metadata data structure (e.g., an address in memory, etc ).
[0043] The NI system 120 is operative to receive metadata data structures 182A-N and transfer data/metadata to an application 178A-N according to the metadata data structures according to multiple embodiments described with reference to Figures 2A-3. The operations in the flow diagrams of Figures 2A-3 will be described with reference to the exemplary embodiments of the other figures. However, it should be understood that the operations of the flow diagrams can be performed by embodiments of the invention other than those discussed with reference to the other figures, and the embodiments of the invention discussed with reference to these other figures can perform operations different than those discussed with reference to the flow diagrams. In the following description similar reference numbers correspond to similar components.
Generation of metadata structure for optimization of metadata transfer to an application [0044] The operations herein will be described with respect to application 178A; however, similar operations can be performed for one or more additional applications from the applications 178A-N for receiving data from the network interface. As discussed above, processing packets/data uses additional data known as metadata. The metadata can be defined by the NI driver and/or the application itself. The metadata includes information on the raw packet received through the NI, such as a length of the packet, a timestamp for the packet, a checksum, and pointers to different protocol stacks in the packet or to metadata that are derived and used by the applications. Additionally or alternatively, the metadata can include user/application metadata (which is sometimes referred to as packet annotations) that is used during the data processing. For example, the application metadata can be calculated/extracted from the packet and used during processing of the packet by the application and/or the network interface. For example, the application metadata can include one or more of headers, labels, networking addresses, etc. (such as Virtual Local Area Network (VLAN) identifier (ID), Multiprotocol Label Switching (MPLS), source & destination Internet Protocol addresses & ports, statistics, and Wi-Fi association, etc.). [0045] Figure 2A illustrates a flow diagram of exemplary operations that can be performed for efficient metadata transfer between a network interface and applications, in accordance with some embodiments. The method 200 can be performed by processing logic that can include hardware (e.g., processing device, circuitry, dedicated logic, programmable logic, microcode, hardware of a device, integrated circuit, etc.), software (e.g., instructions run or executed on a processing device), or a combination thereof. In some embodiments, the method 200 is performed by MDSD 180 of Figure 1 A.
[0046] At operation 202, MDSD 180 receives information, e.g., information 181A-N, regarding metadata. The metadata is to be used by an application 178A for processing packets received through the network interface 110 of the network interface system 120. The information 181A represents the characteristics and/or requirements of the application 178A.
For example, the information 181A can include 1) parameters needed by the application 178A to process packets, 2) an order of access of the parameters by the application 178A, and 3) dependencies between the parameters. The information 181A can be generated or determined from a data structure 179A-N of the application. In some embodiments, the information can be defined as a graph where a node of the graph receives input data, performs actions (adds/changes/removes the data), and passes the output of this action to a next node of the graph. In some embodiments, the information regarding the metadata can also include a size of memory needed by the application for storing the metadata during the processing of packets received from the NT In some embodiments, some or all the information 181 A is received from the application 178A. Additionally or alternatively some or all the information 181 A is received from a user (e.g., a developer of the application 178A, etc.) or a system administrator (e.g., an administrator of the network including the network device 102). MDSD 180 may receive one or more information, e.g., 181A-N, from one or more applications 178A-N respectively. Each information will be used to customize processing/generation of metadata for the associated application from the applications 178A-N.
[0047] In a non-limiting example, the application 178A is a networking function. For example, the application 178A can implement a forwarding function implemented on top of a packet processing framework 176 or networking library 174. The application 178A and/or packet processing framework provides to MDSD 180, a graph defining the information 181 A as well as any data structures (e.g., Packet class) defined by the packet processing framework or the library. In this example, the graph sent from the application or packet processing framework contains a single node where the source and destination Media Access Control (MAC) addresses are swapped. MDSD 180 is informed that these two fields represent the information needed for the application. The application uses these two fields for processing packets received at the network interface 110. In this example, to process a packet, the application 178A needs to access the destination MAC address first and then the source MAC address. Additionally, the application needs a pointer for pointing to the location of MAC addresses in the packet buffer and the address of the packet. In this example, other fields such as packet size, timestamp, and/or other metadata that may be automatically generated by the NI 110 are not needed by the application 178A for processing a packet.
[0048] At operation 204, MDSD 180 determines, based on the information 181 A, a metadata data structure 182 A for the application 178A. When multiple applications provide information, MDSD 180 determines a metadata data structure, e g., 182A-N for each one of the applications, respectively. For example, a first metadata data structure 182A is determined for a first application, e.g., application 178A, and a second metadata data structure 182N is determined for a second application, e g., application 178N. In some embodiments, the two metadata data structures are identical. In other embodiments, the two metadata data structures are different. [0049] The metadata data structure 182A is customized for the application 178A. In some embodiments, the metadata data structure 182A is determined to optimize transfer of metadata from NI 110 to the application 178A. Additionally or alternatively, the metadata data structure 182A is determined to optimize the metadata for usage of application, e g., by re-ordering the access to certain fields/parameters. MDSD 180 analyses the information to determine an appropriate order and priority for transferring the multiple parameters used by the application 178A during the processing of the packets. For example, MDSD 180 can analyze the graph that represents the operations performed on and dependencies between the parameters (e.g., variables and fields) of an application 178A. In some embodiments, additionally or alternatively to analyzing the graph, MDSD 180 performs live variable analysis (also referred to as liveness analysis) on different variables of the application. During liveness analysis, MDSD 180 calculates the variables that are live at each point in time when the application 178A is processing a packet. A variable is live at some point in time if it holds a value that can be needed in the future, or equivalently if its value may be read before the next time the variable is written to. While in some embodiments, MDSD 180 performs the liveness analysis, in other embodiments, MDSD 180 does not perform the liveness analysis.
[0050] During the analysis of the information (the graph and/or the liveness analysis), MDSD 180 can perform the operations of Figure 2B. Figure 2B illustrates a flow diagram of exemplary operations 210 that can be performed for analyzing information related to metadata for an application, in accordance with some embodiments. At operation 212, MDSD 180 identifies a first set of one or more parameters. The first set of parameters includes parameters which are provided in the information but are not used by the application. At operation 214, MDSD 180 identifies a second set of parameters, where a parameter from the second set of parameters is used by the application 178A. At operation 216, MDSD 180 identifies an order of access of the parameters used by the application 178A. At operation 218, MDSD 180 identifies one or more dependencies between one or more parameters of the parameters that are used by the application 178A. In some embodiments, MDSD 180 may perform one or a combination of the operations 212-218.
[0051] MDSD 180 is then operative to generate a metadata data structure 182A that is customized for the application. In some embodiments, the metadata data structure optimizes the storage of the parameters used by the application 178A based on this analysis. Additionally or alternatively, the metadata data structure 182A is determined to optimize the metadata for usage of application, e.g., by re ordering the access to certain fields/parameters. The new metadata data structure may include less parameters as the one included in the information (181 A) and/or have parameters presented in a different order than the order of parameters in the information (181 A) and/or may include more parameters as the one included in the information. The reordering of the parameters in the metadata data structure can be performed based on different criteria, such as the order of access, the popularity of accessed fields, and/or other metrics. For example, MDSD 180 generates a metadata data structure 182A that ensures that the parameters that are accessed consecutively by the application 178A are located on the same or two consecutive cache lines so that they could be fetched faster by a processor during the processing of their related packet (e.g., by efficiently taking advantage of processors prefetching capability). Additionally or alternatively, generating the metadata data structure 182A includes removing parameters that are not used by the application. Additionally or alternatively, generating the metadata data structure 182A includes removing duplicate occurrences of a parameters that is accessed multiple times by the application, if applicable.
[0052] Referring to the packet processing example above, MDSD 180 removes all the unnecessary fields from the packet processing framework/library data structure, and keeps a pointer to the source and destination MAC addresses based on the accessed order on the same cache line (e.g., Destination MAC address followed by source MAC address) and a pointer to the packet.
[0053] Returning to Figure 2A, at operation 206, MDSD 180 updates the application 178A with the metadata data structure 182A. MDSD 180 notifies the application about the metadata data structure 182 A such that the application 178A can use a customized data structure for accessing metadata when processing data received from the NI. MDSD 180 can optionally notify the networking libraries 174 and/or the packet processing framework 176 about the metadata data structure 182A such that the elements of the framework 176 or the libraries 174 used by the application are updated to use the customized metadata data structure. In some embodiments, MDSD 180 communicates with the application 178A through a communication interface that is part of the application (e g., REST API or other). In some embodiments, if the application does not provide a communication interface, MDSD 180 uses a compiler tool chain to modify the source code/intermediate code/binary code of the application 178A and replaces the default application data structures with the newly customized metadata data structure 182A. [0054] The update of the application 178A with the new metadata data structure 182A, causes the application to provide addresses to this metadata data structure and buffers to the network interface The application can send these addresses to the NI driver 172 that transfers them to the NI 110. The NI 110 is then operative to use these addresses to transfer data (e.g., metadata and packets) to the application. The transfer of data can be direct (to the cache 162) or via the main memory 166.
[0055] Referring back to the packet processing example described above, MDSD notifies application 178A about the new metadata data structure for packet processing that contains pointers to the destination and source MAC addresses and a pointer to the packet. If there is no communication interface with the application 178A, MDSD 180 can use available tools (e.g., LLVM tool chain) to modify the source code/binary /intermediate code of the application, the networking libraries 174, and/or packet processing framework 176.
[0056] At operation 208, the MDSD 180 notifies the network interface system 120 with the metadata data structure 182A. The notification of the network interface system 120 causes the network interface system 120 to transfer metadata of packets to the application 178A according to the metadata data structure 182A. In some embodiments, MDSD 180 can interact with the NI driver 172 to transmit the metadata data structure 182A. The NI driver 172 can receive one or more metadata data structures 182A-N for one or more of the applications 178A-N. In some embodiments, the MDSD 180 can interact with the NI 110 to transmit the metadata data structure 182A. The NI 110 can receive one or more metadata data structures 182A-N for one or more of the applications 178A-N.
Generation of metadata for packets of an application [0057] In some embodiments, the NI driver 172 is operative (e.g., via virtualized conversion functions) to generate and/or convert metadata of packets received in the NI 110 and transfer the metadata to the application 178 A according to the metadata data structure. In some embodiments, while the NI driver 172 can be programmed to generate metadata according to the metadata data structure 182A, the NI 110 is not programmable or extendable to include the metadata data structure 182A. The programmability of the NI driver 172 enables MDSD 180 to pass to the NI driver 172 metadata data structures 182A-N that are customized for respective applications 178A-N, as opposed to existing solutions where the NI driver only receives standard/common data structures used by the libraries/frameworks. In these embodiments, the generation of the metadata for the packet based on the metadata data structure can be performed according to the operations of Figure 2C.
[0058] Figure 2C illustrates a flow diagram of exemplary operations 220 that can be performed when a packet is received in a network interface, in accordance with some embodiments. At operation 221, information regarding a metadata data structure 182A is received. For example, the information is received by the NI driver 172. At operation 222, the network interface 110 receives a packet. In some embodiments, the packet is to be processed by the application 178 A. At operation 224, the NI 110 adds the packet to a queue of the network interface 110. At operation 226, the NI 110 determines metadata for the packet based on a data structure of the NI 110. The NI 110 stores the metadata in registers or memory available at the NI 110. Referring to the example above, upon receipt of a packet, the NI 110 may determine metadata such as timestamp, size of a packet, etc. and store them internally in registers or memory available at the NI. The determined metadata may or may not be needed by the application 178A. At operation 228, the NI system 120 transfers updated metadata and the packet to the application according to the metadata data structure 182A. Transferring the updated metadata includes generating, at operation 229, the updated metadata based on the metadata data structure 182A and the metadata generated by the NI 110 for the packet. The determination of the updated metadata can include converting the metadata that is generated in the NTs registers/memory into a format defined by the metadata data structure 182A of the application 178A (e.g., reordering the metadata, removing some metadata, etc.). Additionally or alternatively, the determination of the updated metadata can include generating additional metadata that is not stored in the NT s registers. Transferring the updated metadata further includes storing the updated metadata to the network device’s memory subsystem 164 (e.g., to the cache or the main memory) based on the metadata data structure 182A. The transfer of the updated metadata for the packet allows an efficient access of the metadata by the application. [0059] In the example of the packet processing presented above, the NI driver 172 retrieves the metadata of the NI 110 and stores the pointers to the destination and source MAC addresses and the pointer to the packet as identified in the metadata data structure 182A in the memory subsystem 164 to be accessed by the application 178A. The embodiments described herein, allow for a faster generation of the metadata for the application 178A that avoids unnecessary conversion/copying of data in memory. For example, the embodiments herein avoid two conversions and replaces the conversions of previously existing techniques (e.g., (i) from NI registers/memory to NI driver specific data structures and (ii) from NIC driver data structures to the generic data structures of the framework and libraries, and (iii) from the libraries’ data structures to the application-specific data structures) with one conversion from NI’s registers into a metadata data structure that is customized for the application 178A. In these embodiments, the application is now operative to access the data/packets received in the NI in an optimized format.
Network Interface Enhancement for generation of metadata for packets of an application [0060] In other embodiments, the NI 110 includes a metadata manager 190 that is operative to receive information regarding the metadata data structure and directly generate and store the metadata for a packet according to the metadata data structure without the need of an intermediary operation of storing this information in a data structure of the network interface, and without the need for conversion of the information from the NI’s data structure into the metadata data structure that is customized for the application. While some embodiments described above can be performed in combination with the embodiments described below that include a metadata manager, in other embodiments, these two mechanisms can be implemented separately and independently. For example, in some embodiments, the network device 102 may include either one of the MDSD 180 and the metadata manager 190 providing an efficient I/O data delivery to the application when compared with existing mechanisms. Alternatively, the network device 102 includes the MDSD 180 and the metadata manager 190 providing a more efficient I O data delivery to the application, as it prevents all unnecessary operations.
[0061] Figure 3 illustrates a flow diagram of exemplary operations 300 that can be performed in a network interface for generating metadata according to a metadata data structure, in accordance with some embodiments. The embodiments herein enable different queues of the NI 110 to use different metadata data structures for generation of metadata for multiple applications 182A-N. In some embodiments, the metadata manager 190 is further operative to use additional NI offloading features to create/compute the metadata. For instance, NI 110 can be operative to prefill some packet metadata fields in the metadata data structures so that the application can skip extracting/computing these fields.
[0062] At operation 302, the network interface 110 receives information 192 regarding a metadata data structure for an application. For example, the information 192 can include an identifier 194 of a queue of the network interface that is associated with the application 178A, the metadata data structure to be used for the queue, and an optional indication 194 of additional parameters for metadata that are to be generated by the NI 110. The queue of the network interface is associated with an application 178A when the queue is configured to receive packets destined for processing by the application 178A. In some embodiments, the operation 302 can be performed during an initial configuration phase of the network interface. In some embodiments, the operation 302 can be performed when the application starts operating. Following the configuration of the network interface 110, the network interface can start receiving packets for the applications.
[0063] At operation 304, a packet is received. The packet is added to the queue, at operation 306. The network interface 110 determines, at operation 308, based on the information 192, whether customized metadata is to be generated in the network interface for the packet or NTs default metadata should be generated. For example, the NI manager 130 can interact with the memory communication manager 140 to determine whether there are any memory addresses associated with the receive queue to which the packet is added. In response to determining that there are memory addresses associated with the receive queue, the NI manager 130 interacts with the metadata manager 190 to determine, based on the information 192, the metadata that needs to be generated for the packet in the receive queue. In some embodiments, the NI manager 130 determines that the metadata that needs to be generated includes default metadata, which does not include additional metadata customized for the application 178A. The NI manager 130 may determine that the metadata is the default metadata if there is no identification 195 of metadata data structure for the associated receive queue in the information 192. Additionally or alternatively, the NI manager 130 determines that the metadata that needs to be generated includes metadata customized for the application 178 A based on the metadata data structure identified in the information 192.
[0064] In response to determining that no customized metadata needs to be generated for the packet, the flow moves to operation 310. At operation 310, the NI system 120 transfers the packet to the application and metadata generated according to the NI’s default data structure to the driver 172.
[0065] In response to determining that customized metadata needs to be generated for the packet, the flow moves to operation 312. At operation 312, the NI 110 determines, based on the information 192 the customized metadata for the packet. In some embodiments, the metadata includes customized metadata that is generated according to the metadata data structure 182A for the application 178A.
[0066] In some embodiments, the customized metadata can be generated by the NI 110, e.g., the NI manager 130. The NI manager 130 can interact with the packet in the receive queue to calculate and/or extract the customized metadata. In some embodiments, the generation of the customized metadata can include reordering parameters of the metadata according to an order defined in the metadata data structure 182A. In some embodiments, the generation of the customized metadata can include avoiding the generation of default fields/parameters that would otherwise have been generated according to the default data structure of the NI. When the metadata is determined for the packet, the NI manager 130 notifies the memory communication manager 140 to transfer the packet and its associated metadata to application. Transferring the packet and the metadata to the application can include directly transferring them to the application (to the cache 162 or registers of the processing unit 160) or storing the packet and the metadata in the main memory 166. In the embodiments described herein, the metadata for a packet that is to be processed by an application is determined at the network interface according to a customized metadata data structure for the application. When the network interface is operative to transfer data to more than one application, e.g., to a first application 178A and to a second application 178N, the network interface 110 is operative to transfer metadata to the first application 178A according to a first metadata data structure and transfer metadata to the second application 178N according to a second metadata data structure. The network interface 110 is operative to customize the metadata and generate the customized metadata without the need for multiple conversions and/or copying of data in the memory subsystem 164. While embodiments herein are described with the network interface 110 receiving a metadata data structure 182A that optimizes transfer of the metadata from the network interface 110 to the application and/or is optimized for usage of application, in other embodiments, the network interface 110 can receive a metadata data structure for the application that is not optimized. For example, the metadata data structure can be received from the application without having been modified by a metadata data structure determiner 180 as described above.
Infrastructure:
[0067] An electronic device stores and transmits (internally and/or with other electronic devices over a network) code (which is composed of software instructions and which is sometimes referred to as computer program code or a computer program) and/or data using machine-readable media (also called computer-readable media), such as machine-readable storage media (e.g., magnetic disks, optical disks, solid state drives, read only memory (ROM), flash memory devices, phase change memory) and machine-readable transmission media (also called a carrier) (e.g., electrical, optical, radio, acoustical or other form of propagated signals - such as carrier waves, infrared signals). Thus, an electronic device (e.g., a computer) includes hardware and software, such as a set of one or more processors (e.g., wherein a processor is a microprocessor, controller, microcontroller, central processing unit, digital signal processor, application specific integrated circuit, field programmable gate array, other electronic circuitry, a combination of one or more of the preceding) coupled to one or more machine-readable storage media to store code for execution on the set of processors and/or to store data. For instance, an electronic device may include non-volatile memory containing the code since the non-volatile memory can persist code/data even when the electronic device is turned off (when power is removed), and while the electronic device is turned on that part of the code that is to be executed by the processor(s) of that electronic device is typically copied from the slower non volatile memory into volatile memory (e g., dynamic random access memory (DRAM), static random access memory (SRAM)) of that electronic device. Typical electronic devices also include a set or one or more physical network interface(s) (NI(s)) to establish network connections (to transmit and/or receive code and/or data using propagating signals) with other electronic devices. For example, the set of physical NIs (or the set of physical NI(s) in combination with the set of processors executing code) may perform any formatting, coding, or translating to allow the electronic device to send and receive data whether over a wired and/or a wireless connection. In some embodiments, a physical NI may comprise radio circuitry capable of receiving data from other electronic devices over a wireless connection and/or sending data out to other devices via a wireless connection. This radio circuitry may include transmitted s), receiver(s), and/or transceiver(s) suitable for radiofrequency communication. The radio circuitry may convert digital data into a radio signal having the appropriate parameters (e.g., frequency, timing, channel, bandwidth, etc.). The radio signal may then be transmitted via antennas to the appropriate recipient(s). In some embodiments, the set of physical NI(s) may comprise network interface controller(s) (NICs), also known as a network interface card, network adapter, or local area network (LAN) adapter. The NIC(s) may facilitate in connecting the electronic device to other electronic devices allowing them to communicate via wire through plugging in a cable to a physical port connected to a NIC. One or more parts of an embodiment of the invention may be implemented using different combinations of software, firmware, and/or hardware.
[0068] Figure 4A illustrates connectivity between network devices (NDs) within an exemplary network, as well as three exemplary implementations of the NDs, according to some embodiments of the invention. Figure 4A shows NDs 400A-H, and their connectivity by way of lines between 400A-400B, 400B-400C, 400C-400D, 400D-400E, 400E-400F, 400F-400G, and 400A-400G, as well as between 400H and each of 400A, 400C, 400D, and 400G. These NDs are physical devices, and the connectivity between these NDs can be wireless or wired (often referred to as a link). An additional line extending from NDs 400A, 400E, and 400F illustrates that these NDs act as ingress and egress points for the network (and thus, these NDs are sometimes referred to as edge NDs; while the other NDs may be called core NDs).
[0069] Two of the exemplary ND implementations in Figure 4A are: 1) a special-purpose network device 402 that uses custom application-specific integrated-circuits (ASICs) and a special-purpose operating system (OS); and 2) a general purpose network device 404 that uses common off-the-shelf (COTS) processors and a standard OS. [0070] The special-purpose network device 402 includes networking hardware 410 comprising a set of one or more processor(s) 412, forwarding resource(s) 414 (which typically include one or more ASICs and/or network processors), and physical network interfaces (NIs) 416 (through which network connections are made, such as those shown by the connectivity between NDs 400A-H), as well as non-transitory machine readable storage media 418 having stored therein networking software 420. During operation, the networking software 420 may be executed by the networking hardware 410 to instantiate a set of one or more networking software instance(s) 422. Each of the networking software instance(s) 422, and that part of the networking hardware 410 that executes that network software instance (be it hardware dedicated to that networking software instance and/or time slices of hardware temporally shared by that networking software instance with others of the networking software instance(s) 422), form a separate virtual network element 430A-R. Each of the virtual network element(s) (VNEs) 430A-R includes a control communication and configuration module 432A-R (sometimes referred to as a local control module or control communication module) and forwarding table(s) 434A-R, such that a given virtual network element (e.g., 430A) includes the control communication and configuration module (e.g., 432A), a set of one or more forwarding table(s) (e.g., 434A), and that portion of the networking hardware 410 that executes the virtual network element (e.g., 430A).
[0071] The special-purpose network device 402 is often physically and/or logically considered to include: 1) a ND control plane 424 (sometimes referred to as a control plane) comprising the processor(s) 412 that execute the control communication and configuration module(s) 432A-R; and 2) a ND forwarding plane 426 (sometimes referred to as a forwarding plane, a data plane, or a media plane) comprising the forwarding resource(s) 414 that utilize the forwarding table(s) 434A-R and the physical NIs 416. By way of example, where the ND is a router (or is implementing routing functionality), the ND control plane 424 (the processor(s) 412 executing the control communication and configuration module(s) 432A-R) is typically responsible for participating in controlling how data (e.g., packets) is to be routed (e.g., the next hop for the data and the outgoing physical NI for that data) and storing that routing information in the forwarding table(s) 434A-R, and the ND forwarding plane 426 is responsible for receiving that data on the physical NIs 416 and forwarding that data out the appropriate ones of the physical NIs 416 based on the forwarding table(s) 434A-R.
[0072] Figure 4B illustrates an exemplary way to implement the special-purpose network device 402 according to some embodiments of the invention. Figure 4B shows a special-purpose network device including cards 438 (typically hot pluggable). While in some embodiments the cards 438 are of two types (one or more that operate as the ND forwarding plane 426 (sometimes called line cards), and one or more that operate to implement the ND control plane 424 (sometimes called control cards)), alternative embodiments may combine functionality onto a single card and/or include additional card types (e g., one additional type of card is called a service card, resource card, or multi-application card). A service card can provide specialized processing (e.g., Layer 4 to Layer 7 services (e.g., firewall, Internet Protocol Security (IPsec), Secure Sockets Layer (SSL) / Transport Layer Security (TLS), Intrusion Detection System (IDS), peer-to-peer (P2P), Voice over IP (VoIP) Session Border Controller, Mobile Wireless Gateways (Gateway General Packet Radio Service (GPRS) Support Node (GGSN), Evolved Packet Core (EPC) Gateway)). By way of example, a service card may be used to terminate IPsec tunnels and execute the attendant authentication and encryption algorithms. These cards are coupled together through one or more interconnect mechanisms illustrated as backplane 436 (e.g., a first full mesh coupling the line cards and a second full mesh coupling all of the cards). [0073] Returning to Figure 4A, the general-purpose network device 404 includes hardware 440 comprising a set of one or more processor(s) 442 (which are often COTS processors) and physical NIs 446, as well as non-transitory machine-readable storage media 448 having stored therein software 450. During operation, the processor(s) 442 execute the software 450 to instantiate one or more sets of one or more applications 464A-R. While one embodiment does not implement virtualization, alternative embodiments may use different forms of virtualization. For example, in one such alternative embodiment the virtualization layer 454 represents the kernel of an operating system (or a shim executing on a base operating system) that allows for the creation of multiple instances 462A-R called software containers that may each be used to execute one (or more) of the sets of applications 464A-R; where the multiple software containers (also called virtualization engines, virtual private servers, or jails) are user spaces (typically a virtual memory space) that are separate from each other and separate from the kernel space in which the operating system is run; and where the set of applications running in a given user space, unless explicitly allowed, cannot access the memory of the other processes. In another such alternative embodiment the virtualization layer 454 represents a hypervisor (sometimes referred to as a virtual machine monitor (VMM)) or a hypervisor executing on top of a host operating system, and each of the sets of applications 464A-R is run on top of a guest operating system within an instance 462A-R called a virtual machine (which may in some cases be considered a tightly isolated form of software container) that is run on top of the hypervisor - the guest operating system and application may not know they are running on a virtual machine as opposed to running on a “bare metal” host electronic device, or through para-virtualization the operating system and/or application may be aware of the presence of virtualization for optimization purposes. In yet other alternative embodiments, one, some or all of the applications are implemented as unikemel(s), which can be generated by compiling directly with an application only a limited set of libraries (e.g., from a library operating system (LibOS) including drivers/libraries of OS services) that provide the particular OS services needed by the application. As a unikernel can be implemented to run directly on hardware 440, directly on a hypervisor (in which case the unikernel is sometimes described as running within a LibOS virtual machine), or in a software container, embodiments can be implemented fully with unikemels running directly on a hypervisor represented by virtualization layer 454, unikemels running within software containers represented by instances 462A-R, or as a combination of unikemels and the above-described techniques (e.g., unikemels and virtual machines both run directly on a hypervisor, unikemels and sets of applications that are run in different software containers).
[0074] The instantiation of the one or more sets of one or more applications 464A-R, as well as virtualization if implemented, are collectively referred to as software instance(s) 452. Each set of applications 464A-R, corresponding virtualization construct (e.g., instance 462A-R) if implemented, and that part of the hardware 440 that executes them (be it hardware dedicated to that execution and/or time slices of hardware temporally shared), forms a separate virtual network element(s) 460A-R.
[0075] The virtual network element(s) 460A-R perform similar functionality to the virtual network element(s) 430A-R - e.g., similar to the control communication and configuration module(s) 432A and forwarding table(s) 434A (this virtualization of the hardware 440 is sometimes referred to as network function virtualization (NFV)). Thus, NTV may be used to consolidate many network equipment types onto industry standard high volume server hardware, physical switches, and physical storage, which could be located in Data centers, NDs, and customer premise equipment (CPE). While embodiments of the invention are illustrated with each instance 462A-R corresponding to one VNE 460A-R, alternative embodiments may implement this correspondence at a finer level granularity (e.g., line card virtual machines virtualize line cards, control card virtual machine virtualize control cards, etc.); it should be understood that the techniques described herein with reference to a correspondence of instances 462A-R to VNEs also apply to embodiments where such a finer level of granularity and/or unikemels are used.
[0076] In certain embodiments, the virtualization layer 454 includes a virtual switch that provides similar forwarding services as a physical Ethernet switch. Specifically, this virtual switch forwards traffic between instances 462A-R and the physical NI(s) 446, as well as optionally between the instances 462A-R; in addition, this virtual switch may enforce network isolation between the VNEs 460A-R that by policy are not permitted to communicate with each other (e.g., by honoring virtual local area networks (VLANs)). [0077] The third exemplary ND implementation in Figure 4A is a hybrid network device 406, which includes both custom ASICs/special-purpose OS and COTS processors/standard OS in a single ND or a single card within an ND. In certain embodiments of such a hybrid network device, a platform VM (i.e., a VM that that implements the functionality of the special-purpose network device 402) could provide for para-virtualization to the networking hardware present in the hybrid network device 406.
[0078] Regardless of the above exemplary implementations of an ND, when a single one of multiple VNEs implemented by an ND is being considered (e.g., only one of the VNEs is part of a given virtual network) or where only a single VNE is currently being implemented by an ND, the shortened term network element (NE) is sometimes used to refer to that VNE. Also in all of the above exemplary implementations, each of the VNEs (e g., VNE(s) 430A-R, VNEs 460A-R, and those in the hybrid network device 406) receives data on the physical NIs (e.g., 416, 446) and forwards that data out the appropriate ones of the physical NIs (e.g., 416, 446). For example, a VNE implementing IP router functionality forwards IP packets on the basis of some of the IP header information in the IP packet; where IP header information includes source IP address, destination IP address, source port, destination port (where “source port” and “destination port” refer herein to protocol ports, as opposed to physical ports of a ND), transport protocol (e.g., user datagram protocol (UDP), Transmission Control Protocol (TCP), and differentiated services code point (DSCP) values.
[0079] Figure 4C illustrates various exemplary ways in which VNEs may be coupled according to some embodiments of the invention. Figure 4C shows VNEs 470A.1-470A.P (and optionally VNEs 470A.Q-470A.R) implemented in ND 400A and VNE 470H.1 in ND 400H. In Figure 4C, VNEs 470A.1-P are separate from each other in the sense that they can receive packets from outside ND 400A and forward packets outside of ND 400 A; VNE 470A.1 is coupled with VNE 470H.1, and thus they communicate packets between their respective NDs; VNE 470A.2-470A.3 may optionally forward packets between themselves without forwarding them outside of the ND 400A; and VNE 470A.P may optionally be the first in a chain of VNEs that includes VNE 470A.Q followed by VNE 470A.R (this is sometimes referred to as dynamic service chaining, where each of the VNEs in the series of VNEs provides a different service - e.g., one or more layer 4-7 network services). While Figure 4C illustrates various exemplary relationships between the VNEs, alternative embodiments may support other relationships (e.g., more/fewer VNEs, more/fewer dynamic service chains, multiple different dynamic service chains with some common VNEs and some different VNEs).
[0080] The NDs of Figure 4A, for example, may form part of the Internet or a private network; and other electronic devices (not shown; such as end user devices including workstations, laptops, netbooks, tablets, palm tops, mobile phones, smartphones, phablets, multimedia phones, Voice Over Internet Protocol (VOIP) phones, terminals, portable media players, GPS units, wearable devices, gaming systems, set-top boxes, Internet enabled household appliances) may be coupled to the network (directly or through other networks such as access networks) to communicate over the network (e.g., the Internet or virtual private networks (VPNs) overlaid on (e g., tunneled through) the Internet) with each other (directly or through servers) and/or access content and/or services. Such content and/or services are typically provided by one or more servers (not shown) belonging to a service/content provider or one or more end user devices (not shown) participating in a peer-to-peer (P2P) service, and may include, for example, public webpages (e.g., free content, store fronts, search services), private webpages (e.g., username/password accessed webpages providing email services), and/or corporate networks over VPNs. For instance, end user devices may be coupled (e.g., through customer premise equipment coupled to an access network (wired or wirelessly)) to edge NDs, which are coupled (e.g., through one or more core NDs) to other edge NDs, which are coupled to electronic devices acting as servers. However, through compute and storage virtualization, one or more of the electronic devices operating as the NDs in Figure 4A may also host one or more such servers (e.g., in the case of the general purpose network device 404, one or more of the software instances 462A-R may operate as servers; the same would be true for the hybrid network device 406; in the case of the special-purpose network device 402, one or more such servers could also be run on a virtualization layer executed by the processor(s) 412); in which case the servers are said to be co-located with the VNEs of that ND.
[0081] A virtual network is a logical abstraction of a physical network (such as that in Figure 4A) that provides network services (e.g., L2 and/or L3 services). A virtual network can be implemented as an overlay network (sometimes referred to as a network virtualization overlay) that provides network services (e.g., layer 2 (L2, data link layer) and/or layer 3 (L3, network layer) services) over an underlay network (e.g., an L3 network, such as an Internet Protocol (IP) network that uses tunnels (e.g., generic routing encapsulation (GRE), layer 2 tunneling protocol (L2TP), IPSec) to create the overlay network).
[0082] A network virtualization edge (NVE) sits at the edge of the underlay network and participates in implementing the network virtualization; the network-facing side of the NVE uses the underlay network to tunnel frames to and from other NVEs; the outward-facing side of the NVE sends and receives data to and from systems outside the network. A virtual network instance (VNI) is a specific instance of a virtual network on a NVE (e.g., a NE/VNE on an ND, a part of a NE/VNE on a ND where that NE/VNE is divided into multiple VNEs through emulation); one or more VNIs can be instantiated on an NVE (e.g., as different VNEs on an ND). A virtual access point (VAP) is a logical connection point on the NVE for connecting external systems to a virtual network; a VAP can be physical or virtual ports identified through logical interface identifiers (e.g., a VLAN ID).
[0083] Examples of network services include: 1) an Ethernet LAN emulation service (an Ethernet-based multipoint service similar to an Internet Engineering Task Force (IETF) Multiprotocol Label Switching (MPLS) or Ethernet VPN (EVPN) service) in which external systems are interconnected across the network by a LAN environment over the underlay network (e.g., an NVE provides separate L2 VNIs (virtual switching instances) for different such virtual networks, and L3 (e.g., IP/MPLS) tunneling encapsulation across the underlay network); and 2) a virtualized IP forwarding service (similar to IETF IP VPN (e.g., Border Gateway Protocol (BGP)/MPLS IPVPN) from a service definition perspective) in which external systems are interconnected across the network by an L3 environment over the underlay network (e.g., an NVE provides separate L3 VNIs (forwarding and routing instances) for different such virtual networks, and L3 (e.g., IP/MPLS) tunneling encapsulation across the underlay network)). Network services may also include quality of service capabilities (e.g., traffic classification marking, traffic conditioning and scheduling), security capabilities (e.g., filters to protect customer premises from network originated attacks, to avoid malformed route announcements), and management capabilities (e.g., full detection and processing).
[0084] Figure 4D illustrates a network with a single network element on each of the NDs of Figure 4A, and within this straight forward approach contrasts a traditional distributed approach (commonly used by traditional routers) with a centralized approach for maintaining reachability and forwarding information (also called network control), according to some embodiments of the invention. Specifically, Figure 4D illustrates network elements (NEs) 470A-H with the same connectivity as the NDs 400 A-H of Figure 4 A.
[0085] Figure 4D illustrates that the distributed approach 472 distributes responsibility for generating the reachability and forwarding information across the NEs 470A-H; in other words, the process of neighbor discovery and topology discovery is distributed.
[0086] For example, where the special-purpose network device 402 is used, the control communication and configuration module(s) 432A-R of the ND control plane 424 typically include a reachability and forwarding information module to implement one or more routing protocols (e.g., an exterior gateway protocol such as Border Gateway Protocol (BGP), Interior Gateway Protocol(s) (IGP) (e.g., Open Shortest Path First (OSPF), Intermediate System to Intermediate System (IS-IS), Routing Information Protocol (RIP), Label Distribution Protocol (LDP), Resource Reservation Protocol (RSVP) (including RSVP-Traffic Engineering (TE): Extensions to RSVP for LSP Tunnels and Generalized Multi -Protocol Label Switching (GMPLS) Signaling RSVP-TE)) that communicate with other NEs to exchange routes, and then selects those routes based on one or more routing metrics. Thus, the NEs 470A-H (e.g., the processor(s) 412 executing the control communication and configuration module(s) 432A-R) perform their responsibility for participating in controlling how data (e g., packets) is to be routed (e.g., the next hop for the data and the outgoing physical NI for that data) by distributively determining the reachability within the network and calculating their respective forwarding information. Routes and adjacencies are stored in one or more routing structures (e.g., Routing Information Base (RIB), Label Information Base (LIB), one or more adjacency structures) on the ND control plane 424 The ND control plane 424 programs the ND forwarding plane 426 with information (e.g., adjacency and route information) based on the routing structure(s). For example, the ND control plane 424 programs the adjacency and route information into one or more forwarding table(s) 434A-R (e.g., Forwarding Information Base (FIB), Label Forwarding Information Base (LFIB), and one or more adjacency structures) on the ND forwarding plane 426. For layer 2 forwarding, the ND can store one or more bridging tables that are used to forward data based on the layer 2 information in that data. While the above example uses the special-purpose network device 402, the same distributed approach 472 can be implemented on the general-purpose network device 404 and the hybrid network device 406. [0087] Figure 4D illustrates that a centralized approach 474 (also known as software defined networking (SDN)) that decouples the system that makes decisions about where traffic is sent from the underlying systems that forwards traffic to the selected destination. The illustrated centralized approach 474 has the responsibility for the generation of reachability and forwarding information in a centralized control plane 476 (sometimes referred to as a SDN control module, controller, network controller, OpenFlow controller, SDN controller, control plane node, network virtualization authority, or management control entity), and thus the process of neighbor discovery and topology discovery is centralized. The centralized control plane 476 has a south bound interface 482 with a data plane 480 (sometime referred to the infrastructure layer, network forwarding plane, or forwarding plane (which should not be confused with a ND forwarding plane)) that includes the NEs 470A-H (sometimes referred to as switches, forwarding elements, data plane elements, or nodes). The centralized control plane 476 includes a network controller 478, which includes a centralized reachability and forwarding information module 479 that determines the reachability within the network and distributes the forwarding information to the NEs 470A-H of the data plane 480 over the south bound interface 482 (which may use the OpenFlow protocol). Thus, the network intelligence is centralized in the centralized control plane 476 executing on electronic devices that are typically separate from the NDs. [0088] For example, where the special-purpose network device 402 is used in the data plane 480, each of the control communication and configuration module(s) 432A-R of the ND control plane 424 typically include a control agent that provides the VNE side of the south bound interface 482. In this case, the ND control plane 424 (the processor(s) 412 executing the control communication and configuration module(s) 432A-R) performs its responsibility for participating in controlling how data (e g., packets) is to be routed (e g., the next hop for the data and the outgoing physical NT for that data) through the control agent communicating with the centralized control plane 476 to receive the forwarding information (and in some cases, the reachability information) from the centralized reachability and forwarding information module 479 (it should be understood that in some embodiments of the invention, the control communication and configuration module(s) 432A-R, in addition to communicating with the centralized control plane 476, may also play some role in determining reachability and/or calculating forwarding information - albeit less so than in the case of a distributed approach; such embodiments are generally considered to fall under the centralized approach 474, but may also be considered a hybrid approach).
[0089] While the above example uses the special-purpose network device 402, the same centralized approach 474 can be implemented with the general purpose network device 404 (e.g., each of the VNE 460A-R performs its responsibility for controlling how data (e.g., packets) is to be routed (e.g., the next hop for the data and the outgoing physical NI for that data) by communicating with the centralized control plane 476 to receive the forwarding information (and in some cases, the reachability information) from the centralized reachability and forwarding information module 479; it should be understood that in some embodiments of the invention, the VNEs 460A-R, in addition to communicating with the centralized control plane 476, may also play some role in determining reachability and/or calculating forwarding information - albeit less so than in the case of a distributed approach) and the hybrid network device 406. In fact, the use of SDN techniques can enhance the NFV techniques typically used in the general purpose network device 404 or hybrid network device 406 implementations as NFV is able to support SDN by providing an infrastructure upon which the SDN software can be run, and NFV and SDN both aim to make use of commodity server hardware and physical switches.
[0090] Figure 4D also shows that the centralized control plane 476 has a north bound interface 484 to an application layer 486, in which resides application(s) 488. The centralized control plane 476 has the ability to form virtual networks 492 (sometimes referred to as a logical forwarding plane, network services, or overlay networks (with the NEs 470A-H of the data plane 480 being the underlay network)) for the application(s) 488. Thus, the centralized control plane 476 maintains a global view of all NDs and configured NEs/VNEs, and it maps the virtual networks to the underlying NDs efficiently (including maintaining these mappings as the physical network changes either through hardware (ND, link, or ND component) failure, addition, or removal).
[0091] While Figure 4D shows the distributed approach 472 separate from the centralized approach 474, the effort of network control may be distributed differently or the two combined in certain embodiments of the invention. For example: 1) embodiments may generally use the centralized approach (SDN) 474, but have certain functions delegated to the NEs (e.g., the distributed approach may be used to implement one or more of fault monitoring, performance monitoring, protection switching, and primitives for neighbor and/or topology discovery); or 2) embodiments of the invention may perform neighbor discovery and topology discovery via both the centralized control plane and the distributed protocols, and the results compared to raise exceptions where they do not agree. Such embodiments are generally considered to fall under the centralized approach 474, but may also be considered a hybrid approach.
[0092] While Figure 4D illustrates the simple case where each of the NDs 400A-H implements a single NE 470A-H, it should be understood that the network control approaches described with reference to Figure 4D also work for networks where one or more of the NDs 400A-H implement multiple VNEs (e.g., VNEs 430A-R, VNEs 460A-R, those in the hybrid network device 406). Alternatively or in addition, the network controller 478 may also emulate the implementation of multiple VNEs in a single ND. Specifically, instead of (or in addition to) implementing multiple VNEs in a single ND, the network controller 478 may present the implementation of a VNE/NE in a single ND as multiple VNEs in the virtual networks 492 (all in the same one of the virtual network(s) 492, each in different ones of the virtual network(s)
492, or some combination). For example, the network controller 478 may cause an ND to implement a single VNE (a NE) in the underlay network, and then logically divide up the resources of that NE within the centralized control plane 476 to present different VNEs in the virtual network(s) 492 (where these different VNEs in the overlay networks are sharing the resources of the single VNE/NE implementation on the ND in the underlay network).
[0093] On the other hand, Figures 4E and 4F respectively illustrate exemplary abstractions of NEs and VNEs that the network controller 478 may present as part of different ones of the virtual networks 492. Figure 4E illustrates the simple case of where each of the NDs 400A-H implements a single NE 470A-H (see Figure 4D), but the centralized control plane 476 has abstracted multiple of the NEs in different NDs (the NEs 470A-C and G-H) into (to represent) a single NE 4701 in one of the virtual network(s) 492 of Figure 4D, according to some embodiments of the invention. Figure 4E shows that in this virtual network, the NE 4701 is coupled to NE 470D and 470F, which are both still coupled to NE 470E.
[0094] Figure 4F illustrates a case where multiple VNEs (VNE 470A.1 and VNE 470H.1) are implemented on different NDs (ND 400A and ND 400H) and are coupled to each other, and where the centralized control plane 476 has abstracted these multiple VNEs such that they appear as a single VNE 470T within one of the virtual networks 492 of Figure 4D, according to some embodiments of the invention. Thus, the abstraction of a NE or VNE can span multiple NDs.
[0095] While some embodiments of the invention implement the centralized control plane 476 as a single entity (e.g., a single instance of software running on a single electronic device), alternative embodiments may spread the functionality across multiple entities for redundancy and/or scalability purposes (e.g., multiple instances of software running on different electronic devices).
[0096] Similar to the network device implementations, the electronic device(s) running the centralized control plane 476, and thus the network controller 478 including the centralized reachability and forwarding information module 479, may be implemented a variety of ways (e.g., a special purpose device, a general-purpose (e.g., COTS) device, or hybrid device). These electronic device(s) would similarly include processor(s), a set or one or more physical NIs, and a non-transitory machine-readable storage medium having stored thereon the centralized control plane software. For instance, Figure 5 illustrates, a general purpose control plane device 504 including hardware 540 comprising a set of one or more processor(s) 542 (which are often COTS processors) and physical NIs 546, as well as non-transitory machine readable storage media 548 having stored therein centralized control plane (CCP) software 550.
[0097] In embodiments that use compute virtualization, the processor(s) 542 typically execute software to instantiate a virtualization layer 554 (e.g., in one embodiment the virtualization layer 554 represents the kernel of an operating system (or a shim executing on a base operating system) that allows for the creation of multiple instances 562A-R called software containers (representing separate user spaces and also called virtualization engines, virtual private servers, or jails) that may each be used to execute a set of one or more applications; in another embodiment the virtualization layer 554 represents a hypervisor (sometimes referred to as a virtual machine monitor (VMM)) or a hypervisor executing on top of a host operating system, and an application is run on top of a guest operating system within an instance 562A-R called a virtual machine (which in some cases may be considered a tightly isolated form of software container) that is run by the hypervisor ; in another embodiment, an application is implemented as a unikernel, which can be generated by compiling directly with an application only a limited set of libraries (e.g., from a library operating system (LibOS) including drivers/libraries of OS services) that provide the particular OS services needed by the application, and the unikemel can run directly on hardware 540, directly on a hypervisor represented by virtualization layer 554 (in which case the unikernel is sometimes described as running within a LibOS virtual machine), or in a software container represented by one of instances 562A-R). Again, in embodiments where compute virtualization is used, during operation an instance of the CCP software 550 (illustrated as CCP instance 576A) is executed (e.g., within the instance 562A) on the virtualization layer 554. In embodiments where compute virtualization is not used, the CCP instance 576A is executed, as a unikemel or on top of a host operating system, on the “bare metal” general purpose control plane device 504. The instantiation of the CCP instance 576A, as well as the virtualization layer 554 and instances 562A-R if implemented, are collectively referred to as software instance(s) 552.
[0098] In some embodiments, the CCP instance 576A includes a network controller instance 578. The network controller instance 578 includes a centralized reachability and forwarding information module instance 579 (which is a middleware layer providing the context of the network controller 478 to the operating system and communicating with the various Es), and an CCP application layer 580 (sometimes referred to as an application layer) over the middleware layer (providing the intelligence required for various network operations such as protocols, network situational awareness, and user - interfaces). At a more abstract level, this CCP application layer 580 within the centralized control plane 476 works with virtual network view(s) (logical view(s) of the network) and the middleware layer provides the conversion from the virtual networks to the physical view.
[0099] The centralized control plane 476 transmits relevant messages to the data plane 480 based on CCP application layer 580 calculations and middleware layer mapping for each flow.
A flow may be defined as a set of packets whose headers match a given pattern of bits; in this sense, traditional IP forwarding is also flow-based forwarding where the flows are defined by the destination IP address for example; however, in other implementations, the given pattern of bits used for a flow definition may include more fields (e.g., 10 or more) in the packet headers. Different NDs/NEs/YNEs of the data plane 480 may receive different messages, and thus different forwarding information. The data plane 480 processes these messages and programs the appropriate flow information and corresponding actions in the forwarding tables (sometime referred to as flow tables) of the appropriate NE/V Es, and then the NEs/VNEs map incoming packets to flows represented in the forwarding tables and forward packets based on the matches in the forwarding tables. [00100] Standards such as OpenFlow define the protocols used for the messages, as well as a model for processing the packets. The model for processing packets includes header parsing, packet classification, and making forwarding decisions. Header parsing describes how to interpret a packet based upon a well-known set of protocols. Some protocol fields are used to build a match structure (or key) that will be used in packet classification (e.g., a first key field could be a source media access control (MAC) address, and a second key field could be a destination MAC address).
[00101] Packet classification involves executing a lookup in memory to classify the packet by determining which entry (also referred to as a forwarding table entry or flow entry) in the forwarding tables best matches the packet based upon the match structure, or key, of the forwarding table entries. It is possible that many flows represented in the forwarding table entries can correspond/match to a packet; in this case the system is typically configured to determine one forwarding table entry from the many according to a defined scheme (e.g., selecting a first forwarding table entry that is matched). Forwarding table entries include both a specific set of match criteria (a set of values or wildcards, or an indication of what portions of a packet should be compared to a particular value/values/wildcards, as defined by the matching capabilities for specific fields in the packet header, or for some other packet content), and a set of one or more actions for the data plane to take on receiving a matching packet. For example, an action may be to push a header onto the packet, for the packet using a particular port, flood the packet, or simply drop the packet. Thus, a forwarding table entry for IPv4/IPv6 packets with a particular transmission control protocol (TCP) destination port could contain an action specifying that these packets should be dropped.
[00102] Making forwarding decisions and performing actions occurs, based upon the forwarding table entry identified during packet classification, by executing the set of actions identified in the matched forwarding table entry on the packet.
[00103] However, when an unknown packet (for example, a “missed packet” or a “match- miss” as used in OpenFlow parlance) arrives at the data plane 480, the packet (or a subset of the packet header and content) is typically forwarded to the centralized control plane 476. The centralized control plane 476 will then program forwarding table entries into the data plane 480 to accommodate packets belonging to the flow of the unknown packet. Once a specific forwarding table entry has been programmed into the data plane 480 by the centralized control plane 476, the next packet with matching credentials will match that forwarding table entry and take the set of actions associated with that matched entry.
[00104] A network interface (NT) may be physical or virtual; and in the context of IP, an interface address is an IP address assigned to a NI, be it a physical NI or virtual NI. A virtual NI may be associated with a physical NI, with another virtual interface, or stand on its own (e.g., a loopback interface, a point-to-point protocol interface). A NI (physical or virtual) may be numbered (a NI with an IP address) or unnumbered (a NI without an IP address). A loopback interface (and its loopback address) is a specific type of virtual NI (and IP address) of a NE/VNE (physical or virtual) often used for management purposes; where such an IP address is referred to as the nodal loopback address. The IP address(es) assigned to the NI(s) of a ND are referred to as IP addresses of that ND; at a more granular level, the IP address(es) assigned to NI(s) assigned to a NE/VNE implemented on a ND can be referred to as IP addresses of that NE/VNE.
[00105] While the flow diagrams in the figures show a particular order of operations performed by certain embodiments of the invention, it should be understood that such order is exemplary (e.g., alternative embodiments may perform the operations in a different order, combine certain operations, overlap certain operations, etc.).
[00106] While the invention has been described in terms of several embodiments, those skilled in the art will recognize that the invention is not limited to the embodiments described, can be practiced with modification and alteration within the spirit and scope of the appended claims.
The description is thus to be regarded as illustrative instead of limiting.

Claims

CLAIMS What is claimed is:
1. A method in a network device (102), the method comprising: receiving (202) information (181A) regarding metadata to be used by an application for processing packets received through a network interface (110) of a network interface system (120); determining (204), based on the information (181A), a metadata data structure (182A) that is customized for the application (178A); updating (206) the application (178A) with the metadata data structure (182A); and notifying (208) the network interface system (120) with of the metadata data structure (182A), wherein the notification causes the network interface system (120) to transfer the metadata to the application (178 A) according to the metadata data structure (182 A).
2. The method of claim 1, wherein the determining (204), based on the information (181A), a metadata data structure (182A) includes one or a combination of: identifying (212) a first set of one or more parameters, wherein a first parameter from the first set of parameters is provided in the information (181 A) and is not used by the application (178A); identifying (214) a second set of one or more parameters, wherein a second parameter from the second set of parameters is used by the application (178A); identifying (216) an order of access of the second set of parameters by the application (178A); and identifying (218) one or more dependencies between one or more parameters of the second set of parameters.
3. The method of any of claims 1-2 further comprising: receiving (222) a packet at the network interface (110); adding (224) the packet to a queue of the network interface (110); determining (226), at the network interface (110), metadata for the packet based on a data structure of the network interface (110); and transferring (228) updated metadata and the packet to the application (178A) according to the metadata data structure (182A).
4. The method of claim 3, wherein the transferring (228) the updated metadata and the packet to the application (178A) according to the metadata data structure (182A) includes: generating (229) the updated metadata based on the metadata data structure (182A) and the metadata for the packet.
5. The method of any of claims 1-4, wherein the information (181 A) regarding the metadata includes parameters needed by the application to process packets, an order of access of the parameters by the application, and dependencies between the parameters.
6. The method of any of claims 1-5, wherein the information (181 A) regarding the metadata includes a size of memory needed by the application (178 A) for storing metadata.
7. The method of any of claims 1-6 further comprising: receiving (304) a packet at the network interface (110); adding (306) the packet to a receive queue of the network interface (110); determining (308), based on the information (192), whether customized metadata is to be generated in the network interface (110) for the packet; and responsive to determining (308) that the customized metadata is to be generated in the network interface (110), determining (312), based on the information (192), the customized metadata for the packet, and transferring (314) the customized metadata and the packet to the application (178A) according to the metadata data structure (182A).
8. A network device (102) comprising: a non-transitory machine-readable storage medium that provides instructions that, if executed by a processor, will cause the network device (102) to perform operations comprising, receiving (202) information (181 A) regarding metadata to be used by an application for processing packets received through a network interface (110) of a network interface system (120); determining (204), based on the information (181 A), a metadata data structure (182A) that is customized for the application (178A); updating (206) the application (178A) with the metadata data structure (182A); and notifying (208) the network interface system (120) with of the metadata data structure (182A), wherein the notification causes the network interface system (120) to transfer the metadata to the application (178A) according to the metadata data structure (182A).
9. The network device (102) of claim 8, wherein the determining (204), based on the information (181A), a metadata data structure (182A) includes one or a combination of: identifying (212) a first set of one or more parameters, wherein a first parameter from the first set of parameters is provided in the information (181 A) and is not used by the application (178A); identifying (214) a second set of one or more parameters, wherein a second parameter from the second set of parameters is used by the application (178A); identifying (216) an order of access of the second set of parameters by the application (178 A); and identifying (218) one or more dependencies between one or more parameters of the second set of parameters.
10. The network device (102) of any of claims 8-9 further comprising: receiving (222) a packet at the network interface (110); adding (224) the packet to a queue of the network interface (110); determining (226), at the network interface (110), metadata for the packet based on a data structure of the network interface (110); and transferring (228) updated metadata and the packet to the application (178A) according to the metadata data structure (182A).
11. The network device (102) of claim 10, wherein the transferring (228) the updated metadata and the packet to the application (178A) according to the metadata data structure (182A) includes: generating (229) the updated metadata based on the metadata data structure (182A) and the metadata for the packet.
12. The network device (102) of any of claims 8-11, wherein the information (181A) regarding the metadata includes parameters needed by the application to process packets, an order of access of the parameters by the application, and dependencies between the parameters.
13. The network device (102) of any of claims 8-12, wherein the information (181A) regarding the metadata includes a size of memory needed by the application (178A) for storing metadata.
14. The network device (102) of any of claims 8-13 further comprising: receiving (304) a packet at the network interface (110); adding (306) the packet to a receive queue of the network interface (110); determining (308), based on the information (192), whether customized metadata is to be generated in the network interface (110) for the packet; and responsive to determining (308) that the customized metadata is to be generated in the network interface (110), determining (312), based on the information (192), the customized metadata for the packet, and transferring (314) the customized metadata and the packet to the application (178A) according to the metadata data structure (182A).
15. A machine-readable medium comprising computer program code which when executed by a computer carries out the method steps of any of claims 1-7.
16. A method in a network interface (110), the method comprising: receiving (302) information (192) on a metadata data structure (182A) for an application (178A) that is to process packets received through the network interface (110); receiving (304) a packet at the network interface (110); adding (306) the packet to a receive queue of the network interface (110); determining (308), based on the information (192), whether customized metadata is to be generated in the network interface (110) for the packet; and responsive to determining (308) that the customized metadata is to be generated in the network interface (110), determining (312), based on the information (192), the customized metadata for the packet, and transferring (314) the customized metadata and the packet to the application (178A) according to the metadata data structure (182A).
17. The method of claim 16, wherein the information (192) includes an identifier of a queue of the network interface (194), the metadata data structure to be used for the queue, and an indication (198) of additional metadata that is to be generated by the network interface (110)
18. The method of any of claims 15-16, wherein the determining (308), based on the information (192), whether the customized metadata is to be generated in the network interface (110) for the packet includes: determining whether there are any memory addresses associated with the receive queue; and determining, based on the information (192), the customized metadata that needs to be generated for the packet in the receive queue.
19. The method of any of claims 15-18, wherein the metadata data structure (182A) optimizes transfer of the metadata from the network interface (110) to the application (178A).
20. A machine-readable medium comprising computer program code which when executed by a computer carries out the method steps of any of claims 1-7.
21. A network interface (110) comprising: a non-transitory machine-readable storage medium that provides instructions that, if executed by a processor, will cause the network interface (110) to perform operations comprising, receiving (302) information (192) on a metadata data structure (182A) for an application (178A) that is to process packets received through the network interface (110); receiving (304) a packet at the network interface (110); adding (306) the packet to a receive queue of the network interface (110); determining (308), based on the information (192), whether customized metadata is to be generated in the network interface (110) for the packet; and responsive to determining (308) that the customized metadata is to be generated in the network interface (110), determining (312), based on the information (192), the customized metadata for the packet, and transferring (314) the customized metadata and the packet to the application (178A) according to the metadata data structure
(182A).
22. The network interface (110) of claim 21, wherein the information (192) includes an identifier (194) of a queue of the network interface (110), the metadata data structure to be used for the queue, and an indication (198) of additional metadata that is to be generated by the network interface (110).
23. The network interface (110) of any of claims 21-22, wherein the determining (308), based on the information (192), whether customized metadata is to be generated in the network interface (110) for the packet includes: determining whether there are any memory addresses associated with the receive queue; and determining, based on the information (192), the customized metadata that needs to be generated for the packet in the receive queue.
24. The network interface (110) of any of claims 21-23, wherein the metadata data structure (182A) optimizes transfer of the metadata from the network interface (110) to the application (178A).
PCT/IB2021/052976 2021-04-09 2021-04-09 Methods and systems for efficient metadata and data delivery between a network interface and applications WO2022214854A1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
PCT/IB2021/052976 WO2022214854A1 (en) 2021-04-09 2021-04-09 Methods and systems for efficient metadata and data delivery between a network interface and applications

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/IB2021/052976 WO2022214854A1 (en) 2021-04-09 2021-04-09 Methods and systems for efficient metadata and data delivery between a network interface and applications

Publications (1)

Publication Number Publication Date
WO2022214854A1 true WO2022214854A1 (en) 2022-10-13

Family

ID=75539729

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/IB2021/052976 WO2022214854A1 (en) 2021-04-09 2021-04-09 Methods and systems for efficient metadata and data delivery between a network interface and applications

Country Status (1)

Country Link
WO (1) WO2022214854A1 (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070206490A1 (en) * 2006-03-06 2007-09-06 Cisco Technology, Inc., A California Corporation Applying features to packets in the order specified by a selected feature order template
US8705533B1 (en) * 2010-12-10 2014-04-22 Juniper Networks, Inc. Fast packet encapsulation using templates

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070206490A1 (en) * 2006-03-06 2007-09-06 Cisco Technology, Inc., A California Corporation Applying features to packets in the order specified by a selected feature order template
US8705533B1 (en) * 2010-12-10 2014-04-22 Juniper Networks, Inc. Fast packet encapsulation using templates

Similar Documents

Publication Publication Date Title
US11665089B2 (en) Mechanism for hitless resynchronization during SDN controller upgrades between incompatible versions
EP3879759A1 (en) Optimized datapath troubleshooting with trace policy engine
US11362925B2 (en) Optimizing service node monitoring in SDN
US10623300B2 (en) Method and apparatus for adaptive flow control of link-state information from link-state source to border gateway protocol (BGP)
WO2018203108A1 (en) Efficient troubleshooting in openflow switches
US11956203B2 (en) Service handling in software defined networking based container orchestration systems
US11265104B2 (en) Mechanism for inline packet response generation in software defined networks
WO2020212998A1 (en) Network address allocation in a virtual layer 2 domain spanning across multiple container clusters
US10721157B2 (en) Mechanism to detect data plane loops in an openflow network
WO2018042230A1 (en) Configurable selective packet-in mechanism for openflow switches
US11563698B2 (en) Packet value based packet processing
US20240015108A1 (en) Method and system for efficient input/output transfer in network devices
EP3814897A1 (en) Sliding window based non-busy looping mode in cloud computing
EP3903198B1 (en) Efficient mechanism for executing software-based switching programs on heterogenous multicore processors
WO2022214854A1 (en) Methods and systems for efficient metadata and data delivery between a network interface and applications
US20230421473A1 (en) Method and system for efficient input/output transfer in network devices
WO2022265552A1 (en) System, method, and apparatus for fine-grained control of input/output data placement in a memory subsystem
EP3701686B1 (en) Optimized datapath troubleshooting
WO2023138762A1 (en) System and method for organizing physical queues into virtual queues

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21719281

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 21719281

Country of ref document: EP

Kind code of ref document: A1