1 /*
2 * smb_fs_sb.h
3 *
4 * Copyright (C) 1995 by Paal-Kr. Engstad and Volker Lendecke
5 *
6 */
7
8 #ifndef _SMB_FS_SB
9 #define _SMB_FS_SB
10
11 #include <linux/smb.h>
12 #include <linux/smb_fs_i.h>
13 #include <linux/smb_mount.h>
14 #include <linux/types.h>
15
16 #ifdef __KERNEL__
17
18 struct smb_server {
19 enum smb_protocol protocol; /* The protocol this
20 connection accepts. */
21 enum smb_case_hndl case_handling;
22 struct file * sock_file; /* The socket we transfer
23 data on. */
24 int lock; /* To prevent mismatch in
25 protocols. */
26 struct wait_queue *wait;
27
28 word max_xmit;
29 char hostname[256];
30 word pid;
31 word server_uid;
32 word mid;
33 word tid;
34
35 struct smb_mount_data m; /* We store the complete information here
36 * to be able to reconnect.
37 */
38
39 unsigned short rcls; /* The error codes we received */
40 unsigned short err;
41 unsigned char * packet;
42
43 enum smb_conn_state state;
44 unsigned long reconnect_time; /* The time of the last attempt */
45
46 /* The following are LANMAN 1.0 options transferred to us in
47 SMBnegprot */
48 word secmode;
49 word maxxmt;
50 word maxmux;
51 word maxvcs;
52 word blkmode;
53 dword sesskey;
54
55 /* We use our on data_ready callback, but need the original one */
56 void *data_ready;
57
58 /* We do not have unique numbers for files in the smb protocol
59 like NFS-filehandles. (SMB was designed for DOS, not for
60 UNIX!) So we have to create our own inode numbers. We keep
61 a complete path of smb_inode_info's to each active
62 inode. The inode number is then created by the address of
63 this structure. */
64 struct smb_inode_info root;
65 };
66
67 /*
68 * This is the part of the super-block (in memory) for the SMB file system.
69 */
70
71 struct smb_sb_info {
72 struct smb_server s_server;
73 struct smb_dskattr s_attr;
74 };
75
76 #endif /* __KERNEL__ */
77
78 #endif