Deleted Added
full compact
vpoio.c (39520) vpoio.c (41591)
1/*-
2 * Copyright (c) 1998 Nicolas Souchu
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

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

18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 *
1/*-
2 * Copyright (c) 1998 Nicolas Souchu
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

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

18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 *
26 * $Id: vpoio.c,v 1.2 1998/09/13 18:26:26 nsouch Exp $
26 * $Id: vpoio.c,v 1.3 1998/09/20 14:41:54 nsouch Exp $
27 *
28 */
29
30#ifdef KERNEL
31#include <sys/param.h>
32#include <sys/systm.h>
33#include <sys/malloc.h>
34#include <sys/buf.h>

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

444}
445
446/*
447 * vpoio_instr()
448 */
449static int
450vpoio_instr(struct vpoio_data *vpo, char *buffer, int size)
451{
27 *
28 */
29
30#ifdef KERNEL
31#include <sys/param.h>
32#include <sys/systm.h>
33#include <sys/malloc.h>
34#include <sys/buf.h>

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

444}
445
446/*
447 * vpoio_instr()
448 */
449static int
450vpoio_instr(struct vpoio_data *vpo, char *buffer, int size)
451{
452
453 register int k;
454 int error = 0;
452 int error = 0;
455 int r, mode, epp;
456
457 ppb_MS_exec(&vpo->vpo_dev, MS_OP_GET, buffer, size, MS_UNKNOWN, &error);
458
459#if 0
460 /* XXX EPP 1.9 not implemented with microsequences */
461 else {
462
463 ppb_reset_epp_timeout(&vpo->vpo_dev);

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

483#endif
484
485 return (error);
486}
487
488static char
489vpoio_select(struct vpoio_data *vpo, int initiator, int target)
490{
453
454 ppb_MS_exec(&vpo->vpo_dev, MS_OP_GET, buffer, size, MS_UNKNOWN, &error);
455
456#if 0
457 /* XXX EPP 1.9 not implemented with microsequences */
458 else {
459
460 ppb_reset_epp_timeout(&vpo->vpo_dev);

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

480#endif
481
482 return (error);
483}
484
485static char
486vpoio_select(struct vpoio_data *vpo, int initiator, int target)
487{
491 register int k;
492 int ret;
493
494 struct ppb_microseq select_microseq[] = {
495
496 /* parameter list
497 */
498 #define SELECT_TARGET MS_PARAM(0, 1, MS_TYP_INT)
499 #define SELECT_INITIATOR MS_PARAM(3, 1, MS_TYP_INT)

--- 335 unchanged lines hidden ---
488 int ret;
489
490 struct ppb_microseq select_microseq[] = {
491
492 /* parameter list
493 */
494 #define SELECT_TARGET MS_PARAM(0, 1, MS_TYP_INT)
495 #define SELECT_INITIATOR MS_PARAM(3, 1, MS_TYP_INT)

--- 335 unchanged lines hidden ---