instruction
stringlengths
82
202
input
stringclasses
1 value
output
stringlengths
73
23.9M
Linux işletim sistemi çekirdeği için 'net/core/netmem_priv' yapılarının ve prototiplerinin bulunduğu C Header dosyasını yaz.
```c /* SPDX-License-Identifier: GPL-2.0 */ #ifndef __NETMEM_PRIV_H #define __NETMEM_PRIV_H static inline unsigned long netmem_get_pp_magic(netmem_ref netmem) { return netmem_to_nmdesc(netmem)->pp_magic & ~PP_DMA_INDEX_MASK; } static inline void netmem_or_pp_magic(netmem_ref netmem, unsigned long pp_magic) { netme...
Linux işletim sistemi çekirdeği için 'net/core/devmem' yapılarının ve prototiplerinin bulunduğu C Header dosyasını yaz.
```c /* SPDX-License-Identifier: GPL-2.0-or-later */ /* * Device memory TCP support * * Authors: Mina Almasry <almasrymina@google.com> * Willem de Bruijn <willemb@google.com> * Kaiyuan Zhang <kaiyuanz@google.com> * */ #ifndef _NET_DEVMEM_H #define _NET_DEVMEM_H #include <net/netmem.h> #include <net/netdev_net...
Linux kernel'inin 'net/core/netprio_cgroup' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later /* * net/core/netprio_cgroup.c Priority Control Group * * Authors: Neil Horman <nhorman@tuxdriver.com> */ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt #include <linux/module.h> #include <linux/slab.h> #include <linux/types.h> #include <linux/string.h> #include <lin...
Linux kernel'inin 'net/core/drop_monitor' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-only /* * Monitoring code for network dropped packet alerts * * Copyright (C) 2009 Neil Horman <nhorman@tuxdriver.com> */ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt #include <linux/netdevice.h> #include <linux/etherdevice.h> #include <linux/string.h> #include <linux/if_ar...
Linux kernel'inin 'net/core/hotdata' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later #include <linux/cache.h> #include <linux/jiffies.h> #include <linux/list.h> #include <net/aligned_data.h> #include <net/hotdata.h> #include <net/ip.h> #include <net/proto_memory.h> struct net_hotdata net_hotdata __cacheline_aligned = { .offload_base = LIST_HEAD_INIT(n...
Linux kernel'inin 'net/core/neighbour' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later /* * Generic address resolution entity * * Authors: * Pedro Roque <roque@di.fc.ul.pt> * Alexey Kuznetsov <kuznet@ms2.inr.ac.ru> * * Fixes: * Vitaly E. Lavrov releasing NULL neighbor in neigh_add. * Harald Welte Add neighbour cache statistics like rtstat */ ...
Linux kernel'inin 'net/core/net-procfs' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 #include <linux/netdevice.h> #include <linux/proc_fs.h> #include <linux/seq_file.h> #include <net/wext.h> #include <net/hotdata.h> #include "dev.h" static void *dev_seq_from_index(struct seq_file *seq, loff_t *pos) { unsigned long ifindex = *pos; struct net_device *dev; fo...
Linux kernel'inin 'net/core/dst' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-only /* * net/core/dst.c Protocol independent destination cache. * * Authors: Alexey Kuznetsov, <kuznet@ms2.inr.ac.ru> * */ #include <linux/bitops.h> #include <linux/errno.h> #include <linux/init.h> #include <linux/kernel.h> #include <linux/workqueue.h> #include <linux/mm...
Linux kernel'inin 'net/core/stream' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* * SUCS NET3: * * Generic stream handling routines. These are generic for most * protocols. Even IP. Tonight 8-). * This is used because TCP, LLC (others too) layer all have mostly * identical sendmsg() and recvmsg() code. * So we (will) share it...
Linux kernel'inin 'net/core/datagram' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* * SUCS NET3: * * Generic datagram handling routines. These are generic for all * protocols. Possibly a generic IP version on top of these would * make sense. Not tonight however 8-). * This is used because UDP, RAW, PACKET, DDP, IPX, AX.25 and * NetROM layer all have i...
Linux kernel'inin 'net/core/netdev-genl-gen' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) /* Do not edit directly, auto-generated from: */ /* Documentation/netlink/specs/netdev.yaml */ /* YNL-GEN kernel source */ /* To regenerate run: tools/net/ynl/ynl-regen.sh */ #include <net/netlink.h> #include <net/genetlink.h> #inclu...
Linux kernel'inin 'net/core/of_net' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-only /* * OF helpers for network devices. * * Initially copied out of arch/powerpc/kernel/prom_parse.c */ #include <linux/etherdevice.h> #include <linux/kernel.h> #include <linux/of_net.h> #include <linux/of_platform.h> #include <linux/platform_device.h> #include <linux/phy....
Linux kernel'inin 'net/core/secure_seq' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-only /* * Copyright (C) 2016 Jason A. Donenfeld <Jason@zx2c4.com>. All Rights Reserved. */ #include <linux/kernel.h> #include <linux/init.h> #include <linux/module.h> #include <linux/cache.h> #include <linux/random.h> #include <linux/hrtimer.h> #include <linux/ktime.h> #inclu...
Linux kernel'inin 'net/core/filter' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later /* * Linux Socket Filter - Kernel level socket filtering * * Based on the design of the Berkeley Packet Filter. The new * internal format has been designed by PLUMgrid: * * Copyright (c) 2011 - 2014 PLUMgrid, http://plumgrid.com * * Authors: * * Jay Schulist <...
Linux kernel'inin 'net/core/netclassid_cgroup' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later /* * net/core/netclassid_cgroup.c Classid Cgroupfs Handling * * Authors: Thomas Graf <tgraf@suug.ch> */ #include <linux/slab.h> #include <linux/cgroup.h> #include <linux/fdtable.h> #include <linux/sched/task.h> #include <net/cls_cgroup.h> #include <net/sock.h> st...
Linux kernel'inin 'net/core/lwtunnel' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later /* * lwtunnel Infrastructure for light weight tunnels like mpls * * Authors: Roopa Prabhu, <roopa@cumulusnetworks.com> */ #include <linux/capability.h> #include <linux/module.h> #include <linux/types.h> #include <linux/kernel.h> #include <linux/slab.h> #include <li...
Linux kernel'inin 'net/core/scm' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later /* scm.c - Socket level control messages processing. * * Author: Alexey Kuznetsov, <kuznet@ms2.inr.ac.ru> * Alignment and value checking mods by Craig Metz */ #include <linux/module.h> #include <linux/signal.h> #include <linux/capability.h> #include <l...
Linux kernel'inin 'net/core/fib_notifier' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 #include <linux/rtnetlink.h> #include <linux/notifier.h> #include <linux/rcupdate.h> #include <linux/kernel.h> #include <linux/module.h> #include <linux/init.h> #include <net/net_namespace.h> #include <net/netns/generic.h> #include <net/fib_notifier.h> static unsigned int fib_n...
Linux kernel'inin 'net/core/netdev_queues' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later #include <net/netdev_queues.h> #include <net/netdev_rx_queue.h> #include <net/xdp_sock_drv.h> #include "dev.h" static struct device * __netdev_queue_get_dma_dev(struct net_device *dev, unsigned int idx) { const struct netdev_queue_mgmt_ops *queue_ops = dev->queue_mg...
Linux kernel'inin 'net/core/net-sysfs' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later /* * net-sysfs.c - network device class and attributes * * Copyright (c) 2003 Stephen Hemminger <shemminger@osdl.org> */ #include <linux/capability.h> #include <linux/kernel.h> #include <linux/netdevice.h> #include <linux/if_arp.h> #include <linux/slab.h> #include ...
Linux kernel'inin 'net/core/dev' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later /* * NET3 Protocol independent device support routines. * * Derived from the non IP parts of dev.c 1.0.19 * Authors: Ross Biro * Fred N. van Kempen, <waltje@uWalt.NL.Mugnet.ORG> * Mark Evans, <evansmp@uhura.aston.ac.uk> * * Additional ...
Linux kernel'inin 'net/core/sock_map' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* Copyright (c) 2017 - 2018 Covalent IO, Inc. http://covalent.io */ #include <linux/bpf.h> #include <linux/btf_ids.h> #include <linux/filter.h> #include <linux/errno.h> #include <linux/file.h> #include <linux/net.h> #include <linux/workqueue.h> #include <linux/skmsg.h> #includ...
Linux kernel'inin 'net/core/gro_cells' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 #include <linux/skbuff.h> #include <linux/slab.h> #include <linux/netdevice.h> #include <net/gro_cells.h> #include <net/hotdata.h> struct gro_cell { struct sk_buff_head napi_skbs; struct napi_struct napi; local_lock_t bh_lock; }; int gro_cells_receive(struct gro_cells *gce...
Linux kernel'inin 'net/core/fib_rules' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-only /* * net/core/fib_rules.c Generic Routing Rules * * Authors: Thomas Graf <tgraf@suug.ch> */ #include <linux/types.h> #include <linux/kernel.h> #include <linux/slab.h> #include <linux/list.h> #include <linux/module.h> #include <net/net_namespace.h> #include <net/inet_d...
Linux işletim sistemi çekirdeği için 'net/core/netdev-genl-gen' yapılarının ve prototiplerinin bulunduğu C Header dosyasını yaz.
```c /* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) */ /* Do not edit directly, auto-generated from: */ /* Documentation/netlink/specs/netdev.yaml */ /* YNL-GEN kernel header */ /* To regenerate run: tools/net/ynl/ynl-regen.sh */ #ifndef _LINUX_NETDEV_GEN_H #define _LINUX_NETDEV_GEN_H ...
Linux kernel'inin 'net/core/netdev_config' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-only #include <linux/netdevice.h> #include <net/netdev_queues.h> #include <net/netdev_rx_queue.h> #include "dev.h" static int netdev_nop_validate_qcfg(struct net_device *dev, struct netdev_queue_config *qcfg, struct netlink_ext_ack *extack) { return 0; } sta...
Linux kernel'inin 'net/core/dev_api' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later #include <linux/netdevice.h> #include <net/netdev_lock.h> #include "dev.h" /** * dev_change_name() - change name of a device * @dev: device * @newname: name (or format string) must be at least IFNAMSIZ * * Change name of a device, can pass format strings "eth%d"...
Linux kernel'inin 'net/core/rtnetlink' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later /* * INET An implementation of the TCP/IP protocol suite for the LINUX * operating system. INET is implemented using the BSD Socket * interface as the means of communication with the user level. * * Routing netlink socket interface: protocol independent part....
Linux kernel'inin 'net/core/ptp_classifier' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-only /* PTP classifier */ /* The below program is the bpf_asm (tools/net/) representation of * the opcode array in the ptp_filter structure. * * For convenience, this can easily be altered and reviewed with * bpf_asm and bpf_dbg, e.g. `./bpf_asm -c prog` where prog is a *...
Linux kernel'inin 'net/core/gro' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later #include <net/psp.h> #include <net/gro.h> #include <net/dst_metadata.h> #include <net/busy_poll.h> #include <trace/events/net.h> #include <linux/skbuff_ref.h> #define MAX_GRO_SKBS 8 static DEFINE_SPINLOCK(offload_lock); /** * dev_add_offload - register offload handl...
Linux kernel'inin 'net/core/gso' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later #include <linux/skbuff.h> #include <linux/sctp.h> #include <net/gso.h> #include <net/gro.h> /** * skb_eth_gso_segment - segmentation handler for ethernet protocols. * @skb: buffer to segment * @features: features for the output path (see dev->features) * @type: Eth...
Linux kernel'inin 'net/core/link_watch' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later /* * Linux network device link state notification * * Author: * Stefan Rompf <sux@loplof.de> */ #include <linux/module.h> #include <linux/netdevice.h> #include <linux/if.h> #include <net/sock.h> #include <net/pkt_sched.h> #include <linux/rtnetlink.h> #include ...
Linux kernel'inin 'net/core/skmsg' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* Copyright (c) 2017 - 2018 Covalent IO, Inc. http://covalent.io */ #include <linux/skmsg.h> #include <linux/skbuff.h> #include <linux/scatterlist.h> #include <net/sock.h> #include <net/tcp.h> #include <net/tls.h> #include <trace/events/sock.h> static bool sk_msg_try_coalesc...
Linux kernel'inin 'net/core/sock' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later /* * INET An implementation of the TCP/IP protocol suite for the LINUX * operating system. INET is implemented using the BSD Socket * interface as the means of communication with the user level. * * Generic socket support routines. Memory allocators, socket l...
Linux kernel'inin 'net/core/ieee8021q_helpers' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 // Copyright (c) 2024 Pengutronix, Oleksij Rempel <kernel@pengutronix.de> #include <linux/array_size.h> #include <linux/printk.h> #include <linux/types.h> #include <net/dscp.h> #include <net/ieee8021q.h> /* verify that table covers all 8 traffic types */ #define TT_MAP_SIZE_OK...
Linux kernel'inin 'net/core/page_pool' alt sistemi için gerekli C kaynak kodunu implemente et.
```c /* SPDX-License-Identifier: GPL-2.0 * * page_pool.c * Author: Jesper Dangaard Brouer <netoptimizer@brouer.com> * Copyright (C) 2016 Red Hat, Inc. */ #include <linux/error-injection.h> #include <linux/types.h> #include <linux/kernel.h> #include <linux/slab.h> #include <linux/device.h> #include <net/netdev_lo...
Linux kernel'inin 'net/core/netpoll' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-only /* * Common framework for low-level network console, dump, and debugger code * * Sep 8 2003 Matt Mackall <mpm@selenic.com> * * based on the netconsole code from: * * Copyright (C) 2001 Ingo Molnar <mingo@redhat.com> * Copyright (C) 2002 Red Hat, Inc. */ #define...
Linux işletim sistemi çekirdeği için 'net/core/dev' yapılarının ve prototiplerinin bulunduğu C Header dosyasını yaz.
```c /* SPDX-License-Identifier: GPL-2.0-or-later */ #ifndef _NET_CORE_DEV_H #define _NET_CORE_DEV_H #include <linux/cleanup.h> #include <linux/types.h> #include <linux/rwsem.h> #include <linux/netdevice.h> #include <net/netdev_lock.h> struct net; struct netlink_ext_ack; struct netdev_queue_config; struct cpumask; st...
Linux kernel'inin 'net/core/net_test' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later #include <kunit/test.h> /* GSO */ #include <linux/skbuff.h> static const char hdr[] = "abcdefgh"; #define GSO_TEST_SIZE 1000 static void __init_skb(struct sk_buff *skb) { skb_reset_mac_header(skb); memcpy(skb_mac_header(skb), hdr, sizeof(hdr)); /* skb_segment e...
Linux kernel'inin 'net/core/sysctl_net_core' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* -*- linux-c -*- * sysctl_net_core.c: sysctl interface to net core subsystem. * * Begun April 1, 1996, Mike Shaver. * Added /proc/sys/net/core directory entry (empty =) ). [MS] */ #include <linux/filter.h> #include <linux/mm.h> #include <linux/sysctl.h> #include <linux/m...
Linux kernel'inin 'net/core/utils' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later /* * Generic address resolution entity * * Authors: * net_random Alan Cox * net_ratelimit Andi Kleen * in{4,6}_pton YOSHIFUJI Hideaki, Copyright (C)2006 USAGI/WIDE Project * * Created by Alexey Kuznetsov <kuznet@ms2.inr.ac.ru> */ #include <linux/module.h> #inc...
Linux kernel'inin 'net/core/netdev-genl' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-only #include <linux/netdevice.h> #include <linux/notifier.h> #include <linux/rtnetlink.h> #include <net/busy_poll.h> #include <net/net_namespace.h> #include <net/netdev_queues.h> #include <net/netdev_rx_queue.h> #include <net/sock.h> #include <net/xdp.h> #include <net/xdp_sock...
Linux kernel'inin 'net/core/bpf_sk_storage' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* Copyright (c) 2019 Facebook */ #include <linux/rculist.h> #include <linux/list.h> #include <linux/hash.h> #include <linux/types.h> #include <linux/spinlock.h> #include <linux/bpf.h> #include <linux/btf.h> #include <linux/btf_ids.h> #include <linux/bpf_local_storage.h> #inclu...
Linux kernel'inin 'net/core/tso' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 #include <linux/export.h> #include <linux/if_vlan.h> #include <net/ip.h> #include <net/tso.h> #include <linux/dma-mapping.h> #include <linux/unaligned.h> void tso_build_hdr(const struct sk_buff *skb, char *hdr, struct tso_t *tso, int size, bool is_last) { int hdr_len = sk...
Linux kernel'inin 'net/core/timestamping' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later /* * PTP 1588 clock support - support for timestamping in PHY devices * * Copyright (C) 2010 OMICRON electronics GmbH */ #include <linux/errqueue.h> #include <linux/phy.h> #include <linux/ptp_classify.h> #include <linux/skbuff.h> #include <linux/export.h> #include <...
Linux kernel'inin 'net/core/dev_ioctl' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 #include <linux/kmod.h> #include <linux/netdevice.h> #include <linux/inetdevice.h> #include <linux/etherdevice.h> #include <linux/rtnetlink.h> #include <linux/net_tstamp.h> #include <linux/phylib_stubs.h> #include <linux/ptp_clock_kernel.h> #include <linux/wireless.h> #include <...
Linux kernel'inin 'net/core/skb_fault_injection' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-only #include <linux/debugfs.h> #include <linux/fault-inject.h> #include <linux/netdevice.h> #include <linux/skbuff.h> static struct { struct fault_attr attr; char devname[IFNAMSIZ]; bool filtered; } skb_realloc = { .attr = FAULT_ATTR_INITIALIZER, .filtered = false, }; s...
Linux kernel'inin 'net/core/page_pool_user' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 #include <linux/mutex.h> #include <linux/netdevice.h> #include <linux/xarray.h> #include <net/busy_poll.h> #include <net/net_debug.h> #include <net/netdev_rx_queue.h> #include <net/page_pool/helpers.h> #include <net/page_pool/types.h> #include <net/page_pool/memory_provider.h> ...
Linux kernel'inin 'net/core/net-traces' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* * consolidates trace point definitions * * Copyright (C) 2009 Neil Horman <nhorman@tuxdriver.com> */ #include <linux/netdevice.h> #include <linux/etherdevice.h> #include <linux/string.h> #include <linux/if_arp.h> #include <linux/inetdevice.h> #include <linux/inet.h> #inc...
Linux kernel'inin 'net/core/netevent' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later /* * Network event notifiers * * Authors: * Tom Tucker <tom@opengridcomputing.com> * Steve Wise <swise@opengridcomputing.com> * * Fixes: */ #include <linux/rtnetlink.h> #include <linux/notifier.h> #include <linux/export.h> #inc...
Linux kernel'inin 'net/core/flow_offload' alt sistemi için gerekli C kaynak kodunu implemente et.
```c /* SPDX-License-Identifier: GPL-2.0 */ #include <linux/kernel.h> #include <linux/slab.h> #include <net/act_api.h> #include <net/flow_offload.h> #include <linux/rtnetlink.h> #include <linux/mutex.h> #include <linux/rhashtable.h> struct flow_rule *flow_rule_alloc(unsigned int num_actions) { struct flow_rule *rule;...
Linux kernel'inin 'net/core/pktgen' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later /* * Authors: * Copyright 2001, 2002 by Robert Olsson <robert.olsson@its.uu.se> * Uppsala University and * Swedish University of Agricultural Sciences * * Alexey Kuznetsov <kuznet@ms2.inr.ac.ru> * Ben Greea...
Linux kernel'inin 'net/core/dev_addr_lists_test' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later #include <kunit/test.h> #include <linux/etherdevice.h> #include <linux/math64.h> #include <linux/netdevice.h> #include <linux/rtnetlink.h> static const struct net_device_ops dummy_netdev_ops = { }; #define ADDR_A 1 #define ADDR_B 2 #define ADDR_C 3 struct dev_addr_t...
Linux kernel'inin 'net/core/skbuff' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later /* * Routines having to do with the 'struct sk_buff' memory handlers. * * Authors: Alan Cox <alan@lxorguk.ukuu.org.uk> * Florian La Roche <rzsfl@rz.uni-sb.de> * * Fixes: * Alan Cox : Fixed the worst of the load * balancer bugs. * Dave Platt : Interrupt ...
Linux kernel'inin 'net/core/sock_reuseport' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* * To speed up listener socket lookup, create an array to store all sockets * listening on the same port. This allows a decision to be made after finding * the first socket. An optional BPF program can also be configured for * selecting the socket index from the array of...
Linux kernel'inin 'net/core/gen_stats' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later /* * net/core/gen_stats.c * * Authors: Thomas Graf <tgraf@suug.ch> * Jamal Hadi Salim * Alexey Kuznetsov, <kuznet@ms2.inr.ac.ru> * * See Documentation/networking/gen_stats.rst */ #include <linux/types.h> #include <linux/kernel.h> #include <...
Linux kernel'inin 'net/core/selftests' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* * Copyright (c) 2019 Synopsys, Inc. and/or its affiliates. * stmmac Selftests Support * * Author: Jose Abreu <joabreu@synopsys.com> * * Ported from stmmac by: * Copyright (C) 2021 Oleksij Rempel <o.rempel@pengutronix.de> */ #include <linux/phy.h> #include <net/selfte...
Linux kernel'inin 'net/core/lwt_bpf' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-only /* Copyright (c) 2016 Thomas Graf <tgraf@tgraf.ch> */ #include <linux/filter.h> #include <linux/kernel.h> #include <linux/module.h> #include <linux/skbuff.h> #include <linux/types.h> #include <linux/bpf.h> #include <net/flow.h> #include <net/lwtunnel.h> #include <net/gre....
Linux kernel'inin 'net/core/hwbm' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later /* Support for hardware buffer manager. * * Copyright (C) 2016 Marvell * * Gregory CLEMENT <gregory.clement@free-electrons.com> */ #include <linux/kernel.h> #include <linux/printk.h> #include <linux/skbuff.h> #include <net/hwbm.h> void hwbm_buf_free(struct hwbm_po...
Linux kernel'inin 'net/core/net_namespace' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-only #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt #include <linux/workqueue.h> #include <linux/rtnetlink.h> #include <linux/cache.h> #include <linux/slab.h> #include <linux/list.h> #include <linux/delay.h> #include <linux/sched.h> #include <linux/idr.h> #include <linux/rculist.h...
Linux işletim sistemi çekirdeği için 'net/core/sock_destructor' yapılarının ve prototiplerinin bulunduğu C Header dosyasını yaz.
```c /* SPDX-License-Identifier: GPL-2.0-or-later */ #ifndef _NET_CORE_SOCK_DESTRUCTOR_H #define _NET_CORE_SOCK_DESTRUCTOR_H #include <net/tcp.h> static inline bool is_skb_wmem(const struct sk_buff *skb) { return skb->destructor == sock_wfree || skb->destructor == __sock_wfree || (IS_ENABLED(CONFIG_IN...
Linux işletim sistemi çekirdeği için 'net/core/net-sysfs' yapılarının ve prototiplerinin bulunduğu C Header dosyasını yaz.
```c /* SPDX-License-Identifier: GPL-2.0 */ #ifndef __NET_SYSFS_H__ #define __NET_SYSFS_H__ int __init netdev_kobject_init(void); int netdev_register_kobject(struct net_device *); void netdev_unregister_kobject(struct net_device *); int net_rx_queue_update_kobjects(struct net_device *, int old_num, int new_num); int n...
Linux kernel'inin 'net/core/dev_addr_lists' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later /* * net/core/dev_addr_lists.c - Functions for handling net device lists * Copyright (c) 2010 Jiri Pirko <jpirko@redhat.com> * * This file contains functions for working with unicast, multicast and device * addresses lists. */ #include <linux/netdevice.h> #includ...
Linux kernel'inin 'net/core/xdp' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-only /* net/core/xdp.c * * Copyright (c) 2017 Jesper Dangaard Brouer, Red Hat Inc. */ #include <linux/bpf.h> #include <linux/btf.h> #include <linux/btf_ids.h> #include <linux/filter.h> #include <linux/types.h> #include <linux/mm.h> #include <linux/netdevice.h> #include <linux...
Linux işletim sistemi çekirdeği için 'net/mpls/internal' yapılarının ve prototiplerinin bulunduğu C Header dosyasını yaz.
```c /* SPDX-License-Identifier: GPL-2.0 */ #ifndef MPLS_INTERNAL_H #define MPLS_INTERNAL_H #include <net/mpls.h> /* put a reasonable limit on the number of labels * we will accept from userspace */ #define MAX_NEW_LABELS 30 struct mpls_entry_decoded { u32 label; u8 ttl; u8 tc; u8 bos; }; struct mpls_pcpu_stat...
Linux kernel'inin 'net/mpls/af_mpls' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-only #include <linux/types.h> #include <linux/skbuff.h> #include <linux/socket.h> #include <linux/sysctl.h> #include <linux/net.h> #include <linux/module.h> #include <linux/if_arp.h> #include <linux/ipv6.h> #include <linux/mpls.h> #include <linux/netconf.h> #include <linux/nospe...
Linux kernel'inin 'net/mpls/mpls_iptunnel' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later /* * mpls tunnels An implementation mpls tunnels using the light weight tunnel * infrastructure * * Authors: Roopa Prabhu, <roopa@cumulusnetworks.com> */ #include <linux/types.h> #include <linux/skbuff.h> #include <linux/net.h> #include <linux/module.h> #include <...
Linux kernel'inin 'net/mpls/mpls_gso' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later /* * MPLS GSO Support * * Authors: Simon Horman (horms@verge.net.au) * * Based on: GSO portions of net/ipv4/gre.c */ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt #include <linux/err.h> #include <linux/module.h> #include <linux/netdev_features.h> #include <linux/n...
Linux kernel'inin 'net/handshake/request' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-only /* * Handshake request lifetime events * * Author: Chuck Lever <chuck.lever@oracle.com> * * Copyright (c) 2023, Oracle and/or its affiliates. */ #include <linux/types.h> #include <linux/socket.h> #include <linux/kernel.h> #include <linux/module.h> #include <linux/skb...
Linux kernel'inin 'net/handshake/trace' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* * Trace points for transport security layer handshakes. * * Author: Chuck Lever <chuck.lever@oracle.com> * * Copyright (c) 2023, Oracle and/or its affiliates. */ #include <linux/types.h> #include <linux/ipv6.h> #include <net/sock.h> #include <net/inet_sock.h> #include...
Linux kernel'inin 'net/handshake/genl' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) /* Do not edit directly, auto-generated from: */ /* Documentation/netlink/specs/handshake.yaml */ /* YNL-GEN kernel source */ /* To regenerate run: tools/net/ynl/ynl-regen.sh */ #include <net/netlink.h> #include <net/genetlink.h> #in...
Linux kernel'inin 'net/handshake/netlink' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-only /* * Generic netlink handshake service * * Author: Chuck Lever <chuck.lever@oracle.com> * * Copyright (c) 2023, Oracle and/or its affiliates. */ #include <linux/types.h> #include <linux/socket.h> #include <linux/kernel.h> #include <linux/module.h> #include <linux/skb...
Linux işletim sistemi çekirdeği için 'net/handshake/handshake' yapılarının ve prototiplerinin bulunduğu C Header dosyasını yaz.
```c /* SPDX-License-Identifier: GPL-2.0-only */ /* * Generic netlink handshake service * * Author: Chuck Lever <chuck.lever@oracle.com> * * Copyright (c) 2023, Oracle and/or its affiliates. */ #ifndef _INTERNAL_HANDSHAKE_H #define _INTERNAL_HANDSHAKE_H /* Per-net namespace context */ struct handshake_net { sp...
Linux işletim sistemi çekirdeği için 'net/handshake/genl' yapılarının ve prototiplerinin bulunduğu C Header dosyasını yaz.
```c /* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) */ /* Do not edit directly, auto-generated from: */ /* Documentation/netlink/specs/handshake.yaml */ /* YNL-GEN kernel header */ /* To regenerate run: tools/net/ynl/ynl-regen.sh */ #ifndef _LINUX_HANDSHAKE_GEN_H #define _LINUX_HANDSHA...
Linux kernel'inin 'net/handshake/handshake-test' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* * Copyright (c) 2023 Oracle and/or its affiliates. * * KUnit test of the handshake upcall mechanism. */ #include <kunit/test.h> #include <kunit/visibility.h> #include <linux/kernel.h> #include <net/sock.h> #include <net/genetlink.h> #include <net/netns/generic.h> #inc...
Linux kernel'inin 'net/handshake/tlshd' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-only /* * Establish a TLS session for a kernel socket consumer * using the tlshd user space handler. * * Author: Chuck Lever <chuck.lever@oracle.com> * * Copyright (c) 2021-2023, Oracle and/or its affiliates. */ #include <linux/types.h> #include <linux/socket.h> #include...
Linux kernel'inin 'net/handshake/alert' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-only /* * Handle the TLS Alert protocol * * Author: Chuck Lever <chuck.lever@oracle.com> * * Copyright (c) 2023, Oracle and/or its affiliates. */ #include <linux/types.h> #include <linux/socket.h> #include <linux/kernel.h> #include <linux/module.h> #include <linux/skbuff....
Linux kernel'inin 'net/mptcp/options' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* Multipath TCP * * Copyright (c) 2017 - 2019, Intel Corporation. */ #define pr_fmt(fmt) "MPTCP: " fmt #include <linux/kernel.h> #include <crypto/sha2.h> #include <net/tcp.h> #include <net/mptcp.h> #include "protocol.h" #include "mib.h" #include <trace/events/mptcp.h> st...
Linux kernel'inin 'net/mptcp/subflow' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* Multipath TCP * * Copyright (c) 2017 - 2019, Intel Corporation. */ #define pr_fmt(fmt) "MPTCP: " fmt #include <linux/kernel.h> #include <linux/module.h> #include <linux/netdevice.h> #include <crypto/sha2.h> #include <crypto/utils.h> #include <net/sock.h> #include <net/in...
Linux kernel'inin 'net/mptcp/diag' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* MPTCP socket monitoring support * * Copyright (c) 2019 Red Hat * * Author: Davide Caratti <dcaratti@redhat.com> */ #include <linux/kernel.h> #include <linux/net.h> #include <linux/inet_diag.h> #include <net/netlink.h> #include "protocol.h" static int subflow_get_info(s...
Linux kernel'inin 'net/mptcp/bpf' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* Multipath TCP * * Copyright (c) 2020, Tessares SA. * Copyright (c) 2022, SUSE. * * Author: Nicolas Rybowski <nicolas.rybowski@tessares.net> */ #define pr_fmt(fmt) "MPTCP: " fmt #include <linux/bpf.h> #include "protocol.h" struct mptcp_sock *bpf_mptcp_sock_from_subflo...
Linux kernel'inin 'net/mptcp/pm' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* Multipath TCP * * Copyright (c) 2019, Intel Corporation. */ #define pr_fmt(fmt) "MPTCP: " fmt #include <linux/rculist.h> #include <linux/spinlock.h> #include "protocol.h" #include "mib.h" #define ADD_ADDR_RETRANS_MAX 3 struct mptcp_pm_add_entry { struct list_head list;...
Linux kernel'inin 'net/mptcp/pm_userspace' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* Multipath TCP * * Copyright (c) 2022, Intel Corporation. */ #include "protocol.h" #include "mib.h" #include "mptcp_pm_gen.h" #define mptcp_for_each_userspace_pm_addr(__msk, __entry) \ list_for_each_entry(__entry, \ &((__msk)->pm.userspace_pm_local_addr_lis...
Linux kernel'inin 'net/mptcp/crypto' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* Multipath TCP cryptographic functions * Copyright (c) 2017 - 2019, Intel Corporation. * * Note: This code is based on mptcp_ctrl.c, mptcp_ipv4.c, and * mptcp_ipv6 from multipath-tcp.org, authored by: * * Sébastien Barré <sebastien.barre@uclouvain.be> * ...
Linux işletim sistemi çekirdeği için 'net/mptcp/mptcp_pm_gen' yapılarının ve prototiplerinin bulunduğu C Header dosyasını yaz.
```c /* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) */ /* Do not edit directly, auto-generated from: */ /* Documentation/netlink/specs/mptcp_pm.yaml */ /* YNL-GEN kernel header */ /* To regenerate run: tools/net/ynl/ynl-regen.sh */ #ifndef _LINUX_MPTCP_PM_GEN_H #define _LINUX_MPTCP_PM_...
Linux kernel'inin 'net/mptcp/token_test' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 #include <kunit/test.h> #include "protocol.h" static struct mptcp_subflow_request_sock *build_req_sock(struct kunit *test) { struct mptcp_subflow_request_sock *req; req = kunit_kzalloc(test, sizeof(struct mptcp_subflow_request_sock), GFP_USER); KUNIT_EXPECT_NOT_ERR_...
Linux kernel'inin 'net/mptcp/pm_kernel' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* Multipath TCP * * Copyright (c) 2025, Matthieu Baerts. */ #define pr_fmt(fmt) "MPTCP: " fmt #include <net/netns/generic.h> #include "protocol.h" #include "mib.h" #include "mptcp_pm_gen.h" static int pm_nl_pernet_id; struct pm_nl_pernet { /* protects pernet updates */...
Linux kernel'inin 'net/mptcp/token' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* Multipath TCP token management * Copyright (c) 2017 - 2019, Intel Corporation. * * Note: This code is based on mptcp_ctrl.c from multipath-tcp.org, * authored by: * * Sébastien Barré <sebastien.barre@uclouvain.be> * Christoph Paasch <christoph.paasch@...
Linux kernel'inin 'net/mptcp/sched' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* Multipath TCP * * Copyright (c) 2022, SUSE. */ #define pr_fmt(fmt) "MPTCP: " fmt #include <linux/kernel.h> #include <linux/module.h> #include <linux/list.h> #include <linux/rculist.h> #include <linux/spinlock.h> #include "protocol.h" static DEFINE_SPINLOCK(mptcp_sched_l...
Linux kernel'inin 'net/mptcp/pm_netlink' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* Multipath TCP * * Copyright (c) 2020, Red Hat, Inc. */ #define pr_fmt(fmt) "MPTCP: " fmt #include "protocol.h" #include "mptcp_pm_gen.h" #define MPTCP_PM_CMD_GRP_OFFSET 0 #define MPTCP_PM_EV_GRP_OFFSET 1 static const struct genl_multicast_group mptcp_pm_mc...
Linux kernel'inin 'net/mptcp/syncookies' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 #include <linux/skbuff.h> #include "protocol.h" /* Syncookies do not work for JOIN requests. * * Unlike MP_CAPABLE, where the ACK cookie contains the needed MPTCP * options to reconstruct the initial syn state, MP_JOIN does not contain * the token to obtain the mptcp socke...
Linux kernel'inin 'net/mptcp/ctrl' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* Multipath TCP * * Copyright (c) 2019, Tessares SA. */ #ifdef CONFIG_SYSCTL #include <linux/sysctl.h> #endif #include <net/net_namespace.h> #include <net/netns/generic.h> #include "protocol.h" #include "mib.h" #define MPTCP_SYSCTL_PATH "net/mptcp" static int mptcp_pern...
Linux kernel'inin 'net/mptcp/sockopt' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* Multipath TCP * * Copyright (c) 2021, Red Hat. */ #define pr_fmt(fmt) "MPTCP: " fmt #include <linux/kernel.h> #include <linux/module.h> #include <net/sock.h> #include <net/protocol.h> #include <net/tcp.h> #include <net/mptcp.h> #include "protocol.h" #define MIN_INFO_OPT...
Linux kernel'inin 'net/mptcp/mptcp_diag' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* MPTCP socket monitoring support * * Copyright (c) 2020 Red Hat * * Author: Paolo Abeni <pabeni@redhat.com> */ #include <linux/kernel.h> #include <linux/net.h> #include <linux/inet_diag.h> #include <net/netlink.h> #include "protocol.h" static int sk_diag_dump(struct soc...
Linux kernel'inin 'net/mptcp/protocol' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 /* Multipath TCP * * Copyright (c) 2017 - 2019, Intel Corporation. */ #define pr_fmt(fmt) "MPTCP: " fmt #include <linux/kernel.h> #include <linux/module.h> #include <linux/netdevice.h> #include <linux/sched/signal.h> #include <linux/atomic.h> #include <net/aligned_data.h> #...
Linux kernel'inin 'net/mptcp/mptcp_pm_gen' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) /* Do not edit directly, auto-generated from: */ /* Documentation/netlink/specs/mptcp_pm.yaml */ /* YNL-GEN kernel source */ /* To regenerate run: tools/net/ynl/ynl-regen.sh */ #include <net/netlink.h> #include <net/genetlink.h> #inc...
Linux kernel'inin 'net/mptcp/mib' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0-or-later #include <linux/seq_file.h> #include <net/ip.h> #include <net/mptcp.h> #include <net/snmp.h> #include <net/net_namespace.h> #include "mib.h" static const struct snmp_mib mptcp_snmp_list[] = { SNMP_MIB_ITEM("MPCapableSYNRX", MPTCP_MIB_MPCAPABLEPASSIVE), SNMP_MIB_ITE...
Linux işletim sistemi çekirdeği için 'net/mptcp/mib' yapılarının ve prototiplerinin bulunduğu C Header dosyasını yaz.
```c /* SPDX-License-Identifier: GPL-2.0-or-later */ #include <net/inet_common.h> enum linux_mptcp_mib_field { MPTCP_MIB_NUM = 0, MPTCP_MIB_MPCAPABLEPASSIVE, /* Received SYN with MP_CAPABLE */ MPTCP_MIB_MPCAPABLEACTIVE, /* Sent SYN with MP_CAPABLE */ MPTCP_MIB_MPCAPABLEACTIVEACK, /* Received SYN/ACK with MP_CAPAB...
Linux işletim sistemi çekirdeği için 'net/mptcp/protocol' yapılarının ve prototiplerinin bulunduğu C Header dosyasını yaz.
```c /* SPDX-License-Identifier: GPL-2.0 */ /* Multipath TCP * * Copyright (c) 2017 - 2019, Intel Corporation. */ #ifndef __MPTCP_PROTOCOL_H #define __MPTCP_PROTOCOL_H #include <linux/random.h> #include <net/tcp.h> #include <net/inet_connection_sock.h> #include <uapi/linux/mptcp.h> #include <net/genetlink.h> #incl...
Linux kernel'inin 'net/mptcp/crypto_test' alt sistemi için gerekli C kaynak kodunu implemente et.
```c // SPDX-License-Identifier: GPL-2.0 #include <kunit/test.h> #include "protocol.h" struct test_case { char *key; char *msg; char *result; }; /* we can't reuse RFC 4231 test vectors, as we have constraint on the * input and key size. */ static struct test_case tests[] = { { .key = "0b0b0b0b0b0b0b0b", .m...