<commit_before>/**
 * @file sock.h
 *
 * @brief Definitions for the AF_INET socket handler.
 * @date 17.03.2009
 * @author <NAME>
 */
#ifndef SOCK_H_
#define SOCK_H_

#include <net/skbuff.h>
#include <net/netdevice.h>
#include <net/socket.h>
#include <net/net.h>

typedef struct {
	spinlock_t slock;
} socket_lock_t;

/**
 * Minimal network layer representation of sockets.
 * @param skc_family network address family
 * @param skc_state Connection state
 * @param skc_reuse %SO_REUSEADDR setting
 * @param skc_bound_dev_if bound device index if != 0
 */
struct sock_common {
	unsigned short skc_family;
	volatile unsigned char skc_state;
	unsigned char skc_reuse;
	int skc_bound_dev_if;
#if 0
	struct hlist_node skc_node;
	struct hlist_node skc_bind_node;
	atomic_t skc_refcnt;
	unsigned int skc_hash;
#endif
	struct proto *skc_prot;
};

/**
 * Network layer representation of sockets.
 * @param __sk_common shared layout with inet_timewait_sock
 * @param sk_protocol which protocol this socket belongs in this network family
 * @param sk_type socket type
 * @param sk_rcvbuf size of receive buffer in bytes
 * @param sk_lock synchronizer
 * @param sk_sndbuf size of send buffer in bytes
 * @param sk_flags %SO_LINGER (l_onoff), %SO_BROADCAST, %SO_KEEPALIVE,
 *                %SO_OOBINLINE settings, %SO_TIMESTAMPING settings
 * @param sk_receive_queue incoming packets
 * @param sk_write_queue Packet sending queue
 * @param sk_socket Identd and reporting IO signals
 * @sk_state_change: callback to indicate change in the state of the sock
 * @sk_data_ready: callback to indicate there is data to be processed
 * @sk_write_space: callback to indicate there is bf sending space available
 * @sk_error_report: callback to indicate errors (e.g. %MSG_ERRQUEUE)
 * @sk_backlog_rcv: callback to process the backlog
 * @sk_destruct: called at sock freeing time, i.e. when all refcnt == 0
 */
typedef struct sock {
	struct sock_common __sk_common;<commit_msg>Small fix with bad doxygen formation<commit_after>/**
 * @file sock.h
 *
 * @brief Definitions for the AF_INET socket handler.
 * @date 17.03.2009
 * @author <NAME>
 */
#ifndef SOCK_H_
#define SOCK_H_

#include <net/skbuff.h>
#include <net/netdevice.h>
#include <net/socket.h>
#include <net/net.h>

typedef struct {
	spinlock_t slock;
} socket_lock_t;

/**
 * Minimal network layer representation of sockets.
 * @param skc_family network address family
 * @param skc_state Connection state
 * @param skc_reuse %SO_REUSEADDR setting
 * @param skc_bound_dev_if bound device index if != 0
 */
struct sock_common {
	unsigned short skc_family;
	volatile unsigned char skc_state;
	unsigned char skc_reuse;
	int skc_bound_dev_if;
#if 0
	struct hlist_node skc_node;
	struct hlist_node skc_bind_node;
	atomic_t skc_refcnt;
	unsigned int skc_hash;
#endif
	struct proto *skc_prot;
};

/**
 * Network layer representation of sockets.
 * @param __sk_common shared layout with inet_timewait_sock
 * @param sk_protocol which protocol this socket belongs in this network family
 * @param sk_type socket type
 * @param sk_rcvbuf size of receive buffer in bytes
 * @param sk_lock synchronizer
 * @param sk_sndbuf size of send buffer in bytes
 * @param sk_flags %SO_LINGER (l_onoff), %SO_BROADCAST, %SO_KEEPALIVE,
 *                %SO_OOBINLINE settings, %SO_TIMESTAMPING settings
 * @param sk_receive_queue incoming packets
 * @param sk_write_queue Packet sending queue
 * @param sk_socket Identd and reporting IO signals
 * @param sk_state_change: callback to indicate change in the state of the sock
 * @param sk_data_ready: callback to indicate there is data to be processed
 * @param sk_write_space: callback to indicate there is bf sending space available
 * @param sk_error_report: callback to indicate errors (e.g. %MSG_ERRQUEUE)
 * @param sk_backlog_rcv: callback to process the backlog
 * @param sk_destruct: called at sock freeing time, i.e. when all refcnt == 0
 */
typedef struct sock {
	struct sock_common __sk_common;
{'fraction_non_alphanumeric': 0.07608969513731419, 'fraction_numerical': 0.005542957923910304, 'mean_word_length': 4.671428571428572, 'pattern_counts': {'":': 0, '<': 13, '<?xml version=': 0, '>': 13, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7424289', 'n_tokens_mistral': 1327, 'n_tokens_neox': 1283, 'n_words': 450}