diff options
author | Tim Foster <tim.foster@joyent.com> | 2019-10-25 13:00:51 +0000 |
---|---|---|
committer | Tim Foster <tim.foster@joyent.com> | 2019-10-25 13:00:51 +0000 |
commit | d86c9e6d4e922c695bb2793dddf0ea48d61ca963 (patch) | |
tree | 50a63b04f1ec2b82b50a21df278acff3f24b364e /usr/src/uts/common/sys/socketvar.h | |
parent | 29de67cafe15bb9e2c61bd58e6183182a7735036 (diff) | |
parent | 7284664a1faa361af4ff33ba5435d43d3ee07bf2 (diff) | |
download | illumos-joyent-d86c9e6d4e922c695bb2793dddf0ea48d61ca963.tar.gz |
[illumos-gate merge]
commit 7284664a1faa361af4ff33ba5435d43d3ee07bf2
11816 iscsi initiator gets confused if attached before root file system mount
commit 55908bd733fe029d49237b91c700655997242419
11843 update Intel microcode to 20190918
commit b9c9c3595312927fb362936529c5679117843b93
11826 Buffer overflow and memory leak in "libbsm"
commit 78a2e113edb6fe0a0382b403b55d92e8f0bba78f
9531 Want netstat -u to show PIDs associated with sockets
11707 provide 64-bit libdhcpagent
11708 netstat should be smatch and CERRWARN clean
Conflicts:
usr/src/data/ucode/Makefile
usr/src/data/ucode/README.ucode
usr/src/data/ucode/intel/000206D6-01
usr/src/data/ucode/intel/000206D7-01
usr/src/data/ucode/intel/000306D4-40
usr/src/data/ucode/intel/000306F4-80
usr/src/data/ucode/intel/00040671-02
usr/src/data/ucode/intel/000406F1-01
usr/src/data/ucode/intel/00050654-01
usr/src/data/ucode/intel/00050657-01
usr/src/data/ucode/intel/00050662-10
usr/src/data/ucode/intel/00050663-10
usr/src/data/ucode/intel/00050664-10
usr/src/data/ucode/intel/00050665-10
usr/src/data/ucode/intel/000506CA-01
Diffstat (limited to 'usr/src/uts/common/sys/socketvar.h')
-rw-r--r-- | usr/src/uts/common/sys/socketvar.h | 41 |
1 files changed, 26 insertions, 15 deletions
diff --git a/usr/src/uts/common/sys/socketvar.h b/usr/src/uts/common/sys/socketvar.h index 6794b5687b..55a182fa68 100644 --- a/usr/src/uts/common/sys/socketvar.h +++ b/usr/src/uts/common/sys/socketvar.h @@ -38,6 +38,7 @@ */ /* * Copyright 2015 Nexenta Systems, Inc. All rights reserved. + * Copyright 2019 OmniOS Community Edition (OmniOSce) Association. */ #ifndef _SYS_SOCKETVAR_H @@ -137,7 +138,7 @@ struct sodirect_s; struct sonode { struct vnode *so_vnode; /* vnode associated with this sonode */ - sonodeops_t *so_ops; /* operations vector for this sonode */ + sonodeops_t *so_ops; /* operations vector for this sonode */ void *so_priv; /* sonode private data */ krwlock_t so_fallback_rwlock; @@ -151,12 +152,12 @@ struct sonode { uint_t so_state; /* internal state flags SS_*, below */ uint_t so_mode; /* characteristics on socket. SM_* */ - ushort_t so_flag; /* flags, see below */ + ushort_t so_flag; /* flags, see below */ int so_count; /* count of opened references */ sock_connid_t so_proto_connid; /* protocol generation number */ - ushort_t so_error; /* error affecting connection */ + ushort_t so_error; /* error affecting connection */ struct sockparams *so_sockparams; /* vnode or socket module */ /* Needed to recreate the same socket for accept */ @@ -225,7 +226,7 @@ struct sonode { /* Communication channel with protocol */ sock_lower_handle_t so_proto_handle; - sock_downcalls_t *so_downcalls; + sock_downcalls_t *so_downcalls; struct sock_proto_props so_proto_props; /* protocol settings */ boolean_t so_flowctrld; /* Flow controlled */ @@ -233,7 +234,7 @@ struct sonode { kcondvar_t so_copy_cv; /* Copy cond variable */ /* kernel sockets */ - ksocket_callbacks_t so_ksock_callbacks; + ksocket_callbacks_t so_ksock_callbacks; void *so_ksock_cb_arg; /* callback argument */ kcondvar_t so_closing_cv; @@ -456,7 +457,7 @@ typedef struct smod_info { int smod_version; char *smod_name; uint_t smod_refcnt; /* # of entries */ - size_t smod_uc_version; /* upcall version */ + size_t smod_uc_version; /* upcall version */ size_t smod_dc_version; /* down call version */ so_proto_create_func_t smod_proto_create_func; so_proto_fallback_func_t smod_proto_fallback_func; @@ -531,8 +532,8 @@ extern void sockparams_ephemeral_drop_last_ref(struct sockparams *); extern struct sockparams *sockparams_create(int, int, int, char *, char *, int, int, int, int *); -extern void sockparams_destroy(struct sockparams *); -extern int sockparams_add(struct sockparams *); +extern void sockparams_destroy(struct sockparams *); +extern int sockparams_add(struct sockparams *); extern int sockparams_delete(int, int, int); extern int sockparams_new_filter(struct sof_entry *); extern void sockparams_filter_cleanup(struct sof_entry *); @@ -653,7 +654,7 @@ typedef struct snf_req { int sr_lowat; int sr_operation; struct vnode *sr_vp; - file_t *sr_fp; + file_t *sr_fp; ssize_t sr_maxpsz; u_offset_t sr_file_off; u_offset_t sr_file_size; @@ -679,7 +680,7 @@ struct sendfile_queue { /* Socket network operations switch */ struct sonodeops { - int (*sop_init)(struct sonode *, struct sonode *, cred_t *, + int (*sop_init)(struct sonode *, struct sonode *, cred_t *, int); int (*sop_accept)(struct sonode *, int, cred_t *, struct sonode **); int (*sop_bind)(struct sonode *, struct sockaddr *, socklen_t, @@ -700,13 +701,13 @@ struct sonodeops { int (*sop_shutdown)(struct sonode *, int, cred_t *); int (*sop_getsockopt)(struct sonode *, int, int, void *, socklen_t *, int, cred_t *); - int (*sop_setsockopt)(struct sonode *, int, int, const void *, + int (*sop_setsockopt)(struct sonode *, int, int, const void *, socklen_t, cred_t *); - int (*sop_ioctl)(struct sonode *, int, intptr_t, int, + int (*sop_ioctl)(struct sonode *, int, intptr_t, int, cred_t *, int32_t *); - int (*sop_poll)(struct sonode *, short, int, short *, + int (*sop_poll)(struct sonode *, short, int, short *, struct pollhead **); - int (*sop_close)(struct sonode *, int, cred_t *); + int (*sop_close)(struct sonode *, int, cred_t *); }; #define SOP_INIT(so, flag, cr, flags) \ @@ -987,8 +988,14 @@ extern void so_krecv_unblock(sonode_t *); /* * Internal structure for obtaining sonode information from the socklist. * These types match those corresponding in the sonode structure. - * This is not a published interface, and may change at any time. + * This is not a published interface, and may change at any time. It is + * used for passing information back up to the kstat consumers. By converting + * kernel addresses to strings, we should be able to pass information from + * the kernel to userland regardless of n-bit kernel we are using. */ + +#define ADRSTRLEN (2 * sizeof (uint64_t) + 1) + struct sockinfo { uint_t si_size; /* real length of this struct */ short si_family; @@ -1006,6 +1013,10 @@ struct sockinfo { char si_faddr_sun_path[MAXPATHLEN + 1]; boolean_t si_faddr_noxlate; zoneid_t si_szoneid; + char si_son_straddr[ADRSTRLEN]; + char si_lvn_straddr[ADRSTRLEN]; + char si_fvn_straddr[ADRSTRLEN]; + uint64_t si_inode; }; /* |