Deleted Added
full compact
smb_dev.c (139823) smb_dev.c (144389)
1/*-
2 * Copyright (c) 2000-2001 Boris Popov
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 17 unchanged lines hidden (view full) ---

26 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
27 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
28 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
29 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
30 * SUCH DAMAGE.
31 */
32
33#include <sys/cdefs.h>
1/*-
2 * Copyright (c) 2000-2001 Boris Popov
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 17 unchanged lines hidden (view full) ---

26 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
27 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
28 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
29 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
30 * SUCH DAMAGE.
31 */
32
33#include <sys/cdefs.h>
34__FBSDID("$FreeBSD: head/sys/netsmb/smb_dev.c 139823 2005-01-07 01:45:51Z imp $");
34__FBSDID("$FreeBSD: head/sys/netsmb/smb_dev.c 144389 2005-03-31 12:19:44Z phk $");
35
36#include <sys/param.h>
37#include <sys/kernel.h>
38#include <sys/module.h>
39#include <sys/systm.h>
40#include <sys/conf.h>
41#include <sys/fcntl.h>
42#include <sys/ioccom.h>

--- 61 unchanged lines hidden (view full) ---

104 int u;
105
106 if (*dev != NULL)
107 return;
108 if (dev_stdclone(name, NULL, NSMB_NAME, &u) != 1)
109 return;
110 *dev = make_dev(&nsmb_cdevsw, unit2minor(u), 0, 0, 0600,
111 NSMB_NAME"%d", u);
35
36#include <sys/param.h>
37#include <sys/kernel.h>
38#include <sys/module.h>
39#include <sys/systm.h>
40#include <sys/conf.h>
41#include <sys/fcntl.h>
42#include <sys/ioccom.h>

--- 61 unchanged lines hidden (view full) ---

104 int u;
105
106 if (*dev != NULL)
107 return;
108 if (dev_stdclone(name, NULL, NSMB_NAME, &u) != 1)
109 return;
110 *dev = make_dev(&nsmb_cdevsw, unit2minor(u), 0, 0, 0600,
111 NSMB_NAME"%d", u);
112 dev_ref(*dev);
112}
113
114static int
115nsmb_dev_open(struct cdev *dev, int oflags, int devtype, struct thread *td)
116{
117 struct smb_dev *sdp;
118 struct ucred *cred = td->td_ucred;
119 int s;

--- 297 unchanged lines hidden ---
113}
114
115static int
116nsmb_dev_open(struct cdev *dev, int oflags, int devtype, struct thread *td)
117{
118 struct smb_dev *sdp;
119 struct ucred *cred = td->td_ucred;
120 int s;

--- 297 unchanged lines hidden ---