Deleted Added
full compact
smb_iod.c (176566) smb_iod.c (177599)
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_iod.c 176566 2008-02-25 21:09:16Z attilio $");
34__FBSDID("$FreeBSD: head/sys/netsmb/smb_iod.c 177599 2008-03-25 09:39:02Z ru $");
35
36#include <sys/param.h>
37#include <sys/systm.h>
38#include <sys/endian.h>
39#include <sys/proc.h>
40#include <sys/kernel.h>
41#include <sys/kthread.h>
42#include <sys/malloc.h>

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

256 /*
257 * If all attempts to send a request failed, then
258 * something is seriously hosed.
259 */
260 return ENOTCONN;
261 }
262 SMBSDEBUG("M:%04x, P:%04x, U:%04x, T:%04x\n", rqp->sr_mid, 0, 0, 0);
263 m_dumpm(rqp->sr_rq.mb_top);
35
36#include <sys/param.h>
37#include <sys/systm.h>
38#include <sys/endian.h>
39#include <sys/proc.h>
40#include <sys/kernel.h>
41#include <sys/kthread.h>
42#include <sys/malloc.h>

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

256 /*
257 * If all attempts to send a request failed, then
258 * something is seriously hosed.
259 */
260 return ENOTCONN;
261 }
262 SMBSDEBUG("M:%04x, P:%04x, U:%04x, T:%04x\n", rqp->sr_mid, 0, 0, 0);
263 m_dumpm(rqp->sr_rq.mb_top);
264 m = m_copym(rqp->sr_rq.mb_top, 0, M_COPYALL, M_TRYWAIT);
265 error = rqp->sr_lerror = m ? SMB_TRAN_SEND(vcp, m, td) : ENOBUFS;
264 m = m_copym(rqp->sr_rq.mb_top, 0, M_COPYALL, M_WAIT);
265 error = rqp->sr_lerror = SMB_TRAN_SEND(vcp, m, td);
266 if (error == 0) {
267 getnanotime(&rqp->sr_timesent);
268 iod->iod_lastrqsent = rqp->sr_timesent;
269 rqp->sr_flags |= SMBR_SENT;
270 rqp->sr_state = SMBRQ_SENT;
271 return 0;
272 }
273 /*

--- 447 unchanged lines hidden ---
266 if (error == 0) {
267 getnanotime(&rqp->sr_timesent);
268 iod->iod_lastrqsent = rqp->sr_timesent;
269 rqp->sr_flags |= SMBR_SENT;
270 rqp->sr_state = SMBRQ_SENT;
271 return 0;
272 }
273 /*

--- 447 unchanged lines hidden ---