~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/fs/smb/server/server.h

Version: ~ [ linux-6.11.5 ] ~ [ linux-6.10.14 ] ~ [ linux-6.9.12 ] ~ [ linux-6.8.12 ] ~ [ linux-6.7.12 ] ~ [ linux-6.6.58 ] ~ [ linux-6.5.13 ] ~ [ linux-6.4.16 ] ~ [ linux-6.3.13 ] ~ [ linux-6.2.16 ] ~ [ linux-6.1.114 ] ~ [ linux-6.0.19 ] ~ [ linux-5.19.17 ] ~ [ linux-5.18.19 ] ~ [ linux-5.17.15 ] ~ [ linux-5.16.20 ] ~ [ linux-5.15.169 ] ~ [ linux-5.14.21 ] ~ [ linux-5.13.19 ] ~ [ linux-5.12.19 ] ~ [ linux-5.11.22 ] ~ [ linux-5.10.228 ] ~ [ linux-5.9.16 ] ~ [ linux-5.8.18 ] ~ [ linux-5.7.19 ] ~ [ linux-5.6.19 ] ~ [ linux-5.5.19 ] ~ [ linux-5.4.284 ] ~ [ linux-5.3.18 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.322 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.336 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.337 ] ~ [ linux-4.4.302 ] ~ [ linux-3.10.108 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.9 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

  1 /* SPDX-License-Identifier: GPL-2.0-or-later */
  2 /*
  3  *   Copyright (C) 2018 Samsung Electronics Co., Ltd.
  4  */
  5 
  6 #ifndef __SERVER_H__
  7 #define __SERVER_H__
  8 
  9 #include "smbacl.h"
 10 
 11 /*
 12  * Server state type
 13  */
 14 enum {
 15         SERVER_STATE_STARTING_UP,
 16         SERVER_STATE_RUNNING,
 17         SERVER_STATE_RESETTING,
 18         SERVER_STATE_SHUTTING_DOWN,
 19 };
 20 
 21 /*
 22  * Server global config string index
 23  */
 24 enum {
 25         SERVER_CONF_NETBIOS_NAME,
 26         SERVER_CONF_SERVER_STRING,
 27         SERVER_CONF_WORK_GROUP,
 28 };
 29 
 30 struct ksmbd_server_config {
 31         unsigned int            flags;
 32         unsigned int            state;
 33         short                   signing;
 34         short                   enforced_signing;
 35         short                   min_protocol;
 36         short                   max_protocol;
 37         unsigned short          tcp_port;
 38         unsigned short          ipc_timeout;
 39         unsigned long           ipc_last_active;
 40         unsigned long           deadtime;
 41         unsigned int            share_fake_fscaps;
 42         struct smb_sid          domain_sid;
 43         unsigned int            auth_mechs;
 44         unsigned int            max_connections;
 45 
 46         char                    *conf[SERVER_CONF_WORK_GROUP + 1];
 47         struct task_struct      *dh_task;
 48 };
 49 
 50 extern struct ksmbd_server_config server_conf;
 51 
 52 int ksmbd_set_netbios_name(char *v);
 53 int ksmbd_set_server_string(char *v);
 54 int ksmbd_set_work_group(char *v);
 55 
 56 char *ksmbd_netbios_name(void);
 57 char *ksmbd_server_string(void);
 58 char *ksmbd_work_group(void);
 59 
 60 static inline int ksmbd_server_running(void)
 61 {
 62         return READ_ONCE(server_conf.state) == SERVER_STATE_RUNNING;
 63 }
 64 
 65 static inline int ksmbd_server_configurable(void)
 66 {
 67         return READ_ONCE(server_conf.state) < SERVER_STATE_RESETTING;
 68 }
 69 
 70 int server_queue_ctrl_init_work(void);
 71 int server_queue_ctrl_reset_work(void);
 72 #endif /* __SERVER_H__ */
 73 

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

sflogo.php