Date: Tue, 3 Nov 2009 20:19:06 GMT From: Alexander Motin <mav@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 170128 for review Message-ID: <200911032019.nA3KJ6WT089654@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://p4web.freebsd.org/chv.cgi?CH=170128 Change 170128 by mav@mav_mavtest on 2009/11/03 20:18:18 Remove CAM_PERIPH_POLLED flag. It is broken by design. Polling can't be periph flag. May be SIM, may be CCB, but now it works fine just without it. Affected files ... .. //depot/projects/scottl-camlock/src/sys/cam/ata/ata_da.c#37 edit .. //depot/projects/scottl-camlock/src/sys/cam/cam_periph.h#20 edit .. //depot/projects/scottl-camlock/src/sys/cam/cam_xpt.c#118 edit .. //depot/projects/scottl-camlock/src/sys/cam/scsi/scsi_da.c#51 edit Differences ... ==== //depot/projects/scottl-camlock/src/sys/cam/ata/ata_da.c#37 (text+ko) ==== @@ -373,7 +373,6 @@ } if (length > 0) { - periph->flags |= CAM_PERIPH_POLLED; xpt_setup_ccb(&ccb.ccb_h, periph->path, CAM_PRIORITY_NORMAL); ccb.ccb_h.ccb_state = ADA_CCB_DUMP; cam_fill_ataio(&ccb.ataio, @@ -433,7 +432,6 @@ /*timeout*/0, /*getcount_only*/0); } - periph->flags &= ~CAM_PERIPH_POLLED; cam_periph_unlock(periph); return (0); } ==== //depot/projects/scottl-camlock/src/sys/cam/cam_periph.h#20 (text+ko) ==== @@ -117,7 +117,6 @@ #define CAM_PERIPH_INVALID 0x08 #define CAM_PERIPH_NEW_DEV_FOUND 0x10 #define CAM_PERIPH_RECOVERY_INPROG 0x20 -#define CAM_PERIPH_POLLED 0x40 u_int32_t immediate_priority; u_int32_t refcount; SLIST_HEAD(, ccb_hdr) ccb_list; /* For "immediate" requests */ ==== //depot/projects/scottl-camlock/src/sys/cam/cam_xpt.c#118 (text+ko) ==== @@ -4257,9 +4257,7 @@ links); mtx_unlock(&cam_simq_lock); sim->flags |= CAM_SIM_ON_DONEQ; - if ((done_ccb->ccb_h.path->periph->flags & - CAM_PERIPH_POLLED) == 0) - swi_sched(cambio_ih, 0); + swi_sched(cambio_ih, 0); } break; default: ==== //depot/projects/scottl-camlock/src/sys/cam/scsi/scsi_da.c#51 (text+ko) ==== @@ -859,7 +859,6 @@ } if (length > 0) { - periph->flags |= CAM_PERIPH_POLLED; xpt_setup_ccb(&csio.ccb_h, periph->path, CAM_PRIORITY_NORMAL); csio.ccb_h.ccb_state = DA_CCB_DUMP; scsi_read_write(&csio, @@ -885,7 +884,6 @@ else printf("status == 0x%x, scsi status == 0x%x\n", csio.ccb_h.status, csio.scsi_status); - periph->flags |= CAM_PERIPH_POLLED; return(EIO); } cam_periph_unlock(periph); @@ -929,7 +927,6 @@ } } } - periph->flags &= ~CAM_PERIPH_POLLED; cam_periph_unlock(periph); return (0); }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200911032019.nA3KJ6WT089654>