From owner-freebsd-scsi@FreeBSD.ORG Mon Jun 4 11:07:48 2012 Return-Path: Delivered-To: freebsd-scsi@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 6FC5D106566C for ; Mon, 4 Jun 2012 11:07:48 +0000 (UTC) (envelope-from owner-bugmaster@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 5907C8FC17 for ; Mon, 4 Jun 2012 11:07:48 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.5/8.14.5) with ESMTP id q54B7mZg017568 for ; Mon, 4 Jun 2012 11:07:48 GMT (envelope-from owner-bugmaster@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q54B7l2x017566 for freebsd-scsi@FreeBSD.org; Mon, 4 Jun 2012 11:07:47 GMT (envelope-from owner-bugmaster@FreeBSD.org) Date: Mon, 4 Jun 2012 11:07:47 GMT Message-Id: <201206041107.q54B7l2x017566@freefall.freebsd.org> X-Authentication-Warning: freefall.freebsd.org: gnats set sender to owner-bugmaster@FreeBSD.org using -f From: FreeBSD bugmaster To: freebsd-scsi@FreeBSD.org Cc: Subject: Current problem reports assigned to freebsd-scsi@FreeBSD.org X-BeenThere: freebsd-scsi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SCSI subsystem List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 04 Jun 2012 11:07:48 -0000 Note: to view an individual PR, use: http://www.freebsd.org/cgi/query-pr.cgi?pr=(number). The following is a listing of current problems submitted by FreeBSD users. These represent problem reports covering all versions including experimental development code and obsolete releases. S Tracker Resp. Description -------------------------------------------------------------------------------- o kern/165982 scsi [mpt] mpt instability, drive resets, and losses on Fre o kern/165740 scsi [cam] SCSI code must drain callbacks before free o kern/163713 scsi [aic7xxx] [patch] Add Adaptec29329LPE to aic79xx_pci.c o kern/162256 scsi [mpt] QUEUE FULL EVENT and 'mpt_cam_event: 0x0' o kern/161809 scsi [cam] [patch] set kern.cam.boot_delay via build option o kern/159412 scsi [ciss] 7.3 RELEASE: ciss0 ADAPTER HEARTBEAT FAILED err o kern/157770 scsi [iscsi] [panic] iscsi_initiator panic o kern/154432 scsi [xpt] run_interrupt_driven_hooks: still waiting after o kern/153514 scsi [cam] [panic] CAM related panic o kern/153361 scsi [ciss] Smart Array 5300 boot/detect drive problem o kern/152250 scsi [ciss] [patch] Kernel panic when hw.ciss.expose_hidden o kern/151564 scsi [ciss] ciss(4) should increase CISS_MAX_LOGICAL to 10 o docs/151336 scsi Missing documentation of scsi_ and ata_ functions in c s kern/149927 scsi [cam] hard drive not stopped before removing power dur o kern/148083 scsi [aac] Strange device reporting o kern/147704 scsi [mpt] sys/dev/mpt: new chip revision, partially unsupp o kern/146287 scsi [ciss] ciss(4) cannot see more than one SmartArray con o kern/145768 scsi [mpt] can't perform I/O on SAS based SAN disk in freeb o kern/144648 scsi [aac] Strange values of speed and bus width in dmesg o kern/144301 scsi [ciss] [hang] HP proliant server locks when using ciss o kern/142351 scsi [mpt] LSILogic driver performance problems o kern/134488 scsi [mpt] MPT SCSI driver probes max. 8 LUNs per device o kern/132250 scsi [ciss] ciss driver does not support more then 15 drive o kern/132206 scsi [mpt] system panics on boot when mirroring and 2nd dri o kern/130621 scsi [mpt] tranfer rate is inscrutable slow when use lsi213 o kern/129602 scsi [ahd] ahd(4) gets confused and wedges SCSI bus o kern/128452 scsi [sa] [panic] Accessing SCSI tape drive randomly crashe o kern/128245 scsi [scsi] "inquiry data fails comparison at DV1 step" [re o kern/127927 scsi [isp] isp(4) target driver crashes kernel when set up o kern/127717 scsi [ata] [patch] [request] - support write cache toggling o kern/123674 scsi [ahc] ahc driver dumping o kern/123520 scsi [ahd] unable to boot from net while using ahd o sparc/121676 scsi [iscsi] iscontrol do not connect iscsi-target on sparc o kern/120487 scsi [sg] scsi_sg incompatible with scanners o kern/120247 scsi [mpt] FreeBSD 6.3 and LSI Logic 1030 = only 3.300MB/s o kern/114597 scsi [sym] System hangs at SCSI bus reset with dual HBAs o kern/110847 scsi [ahd] Tyan U320 onboard problem with more than 3 disks o kern/99954 scsi [ahc] reading from DVD failes on 6.x [regression] o kern/92798 scsi [ahc] SCSI problem with timeouts o kern/90282 scsi [sym] SCSI bus resets cause loss of ch device o kern/76178 scsi [ahd] Problem with ahd and large SCSI Raid system o kern/74627 scsi [ahc] [hang] Adaptec 2940U2W Can't boot 5.3 s kern/61165 scsi [panic] kernel page fault after calling cam_send_ccb o kern/60641 scsi [sym] Sporadic SCSI bus resets with 53C810 under load o kern/60598 scsi wire down of scsi devices conflicts with config s kern/57398 scsi [mly] Current fails to install on mly(4) based RAID di o kern/52638 scsi [panic] SCSI U320 on SMP server won't run faster than o kern/44587 scsi dev/dpt/dpt.h is missing defines required for DPT_HAND o kern/39388 scsi ncr/sym drivers fail with 53c810 and more than 256MB m o kern/35234 scsi World access to /dev/pass? (for scanner) requires acce 50 problems total. From owner-freebsd-scsi@FreeBSD.ORG Tue Jun 5 12:19:34 2012 Return-Path: Delivered-To: freebsd-scsi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 22C4C106564A; Tue, 5 Jun 2012 12:19:34 +0000 (UTC) (envelope-from Kashyap.Desai@lsi.com) Received: from na3sys009aog134.obsmtp.com (na3sys009aog134.obsmtp.com [74.125.149.83]) by mx1.freebsd.org (Postfix) with ESMTP id 263348FC1A; Tue, 5 Jun 2012 12:19:33 +0000 (UTC) Received: from paledge01.lsi.com ([192.19.193.42]) (using TLSv1) by na3sys009aob134.postini.com ([74.125.148.12]) with SMTP ID DSNKT835QUQW9Xh3uHPdEALNOXfDPjq3GQfs@postini.com; Tue, 05 Jun 2012 05:19:33 PDT Received: from PALCAS01.lsi.com (128.94.213.117) by PALEDGE01.lsi.com (192.19.193.42) with Microsoft SMTP Server (TLS) id 8.3.213.0; Tue, 5 Jun 2012 08:25:13 -0400 Received: from inbexch02.lsi.com (135.36.98.40) by PALCAS01.lsi.com (128.94.213.117) with Microsoft SMTP Server (TLS) id 8.3.213.0; Tue, 5 Jun 2012 08:19:10 -0400 Received: from inbmail01.lsi.com ([135.36.98.64]) by inbexch02.lsi.com ([135.36.98.40]) with mapi; Tue, 5 Jun 2012 17:49:07 +0530 From: "Desai, Kashyap" To: Konstantin Belousov , "Kenneth D. Merry" Date: Tue, 5 Jun 2012 17:49:05 +0530 Thread-Topic: Kernel panic in FreeBSD-8.3 from UFS Thread-Index: Ac0/9kNdhRScgfZLQl6YJCXP03aRdADFdYIg Message-ID: References: <20120601124338.GU2358@deviant.kiev.zoral.com.ua> <20120601125824.GV2358@deviant.kiev.zoral.com.ua> In-Reply-To: <20120601125824.GV2358@deviant.kiev.zoral.com.ua> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: yes X-MS-TNEF-Correlator: acceptlanguage: en-US Content-Type: multipart/mixed; boundary="_002_B2FD678A64EAAD45B089B123FDFC3ED72B9F6C21A7inbmail01lsic_" MIME-Version: 1.0 Cc: "freebsd-fs@freebsd.org" , "freebsd-scsi@freebsd.org" , "McConnell, Stephen" , "Reddy, Sreekanth" Subject: RE: Kernel panic in FreeBSD-8.3 from UFS X-BeenThere: freebsd-scsi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SCSI subsystem List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 05 Jun 2012 12:19:34 -0000 --_002_B2FD678A64EAAD45B089B123FDFC3ED72B9F6C21A7inbmail01lsic_ Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Hi All, We found some potential area of memory leak in CAM layer.=20 CAM XPT Memory leak is due to following function in scsi/scsi_all.c int scsi_command_string(struct ccb_scsiio *csio, struct sbuf *sb) = =20 In above function, CAM layer allocate memory for ccb device as below if ((cgd =3D (struct ccb_getdev*)xpt_alloc_ccb_nowait()) =3D=3D NULL) _But_, unfortunately we never free the allocated memory and we see memory l= eak of 2K every time when someone is calling=20 Scsi_command_string from kernel mode. Attached is a proposed patch for this issue. ` Kashyap > -----Original Message----- > From: Konstantin Belousov [mailto:kostikbel@gmail.com] > Sent: Friday, June 01, 2012 6:28 PM > To: Desai, Kashyap > Cc: freebsd-scsi@freebsd.org; freebsd-fs@freebsd.org; McConnell, Stephen > Subject: Re: Kernel panic in FreeBSD-8.3 from UFS >=20 > On Fri, Jun 01, 2012 at 06:19:56PM +0530, Desai, Kashyap wrote: > > > > Thanks for the information. *YES* to me also looks like memory leaks > only.. but it is CAM XPT who is using "366195K " memory.. > > > Yes, it seems that cam should be investigated next. >=20 > It is indeed most likely not related to UFS at all, and just happens to > trace through the UFS code since you might have run fs-intensive test > and filesystem just called allocator most often. >=20 > > See below output of "vmstat -m" > > > > vmstat -m > > > > Type InUse MemUse HighUse Requests Size(s) > > feeder 7 1K - 7 16 > > acpiintr 1 1K - 1 32 > > isadev 9 1K - 9 64 > > acpica 3179 172K - 73127 > 16,32,64,128,256,512,1024,2048 > > cdev 7 1K - 7 128 > > acpitask 1 1K - 1 1024 > > sigio 1 1K - 1 32 > > filedesc 50 14K - 2926 16,256,512,1024 > > kenv 121 9K - 130 16,32,64,128,4096 > > kqueue 0 0K - 266 128,1024 > > CAM dev queue 8 1K - 8 128 > > proc-args 26 2K - 4746 16,32,64,128 > > hhook 2 1K - 2 128 > > ithread 128 11K - 128 16,64,128 > > CAM queue 43 9K - 595257 > 16,32,64,128,256,512,1024,2048,4096 > > KTRACE 100 13K - 100 128 > > acpisem 21 3K - 21 64,128 > > linker 157 6K - 166 16,32,256 > > lockf 1751 61K - 2311 32,64,128,256,512,1024 > > loginclass 2 1K - 96 64 > > ip6ndp 12 1K - 13 64,128 > > ip6opt 0 0K - 3 32 > > temp 56 233K - 11165 > 16,32,64,128,256,512,1024,2048,4096 > > devbuf 5248 4507K - 5360 > 16,32,64,128,256,512,1024,2048,4096 > > module 493 31K - 493 64,128 > > mtx_pool 2 8K - 2 4096 > > CAM SIM 8 1K - 8 128 > > subproc 216 219K - 3091 256,4096 > > proc 2 8K - 2 4096 > > session 18 2K - 109 64 > > pgrp 25 2K - 129 64 > > cred 62 6K - 13960 64,128 > > uidinfo 3 2K - 88 64,1024 > > plimit 18 5K - 1389 256 > > scsi_cd 0 0K - 4 16 > > CAM periph 22 3K - 84532 16,32,64,128 > > CAM XPT 183208 366195K - 722021 16,32,64,256,1024,2048 > > sysctltmp 0 0K - 453 16,32,64,128,4096 > > sysctloid 5010 158K - 5286 16,32,64,128 > > sysctl 0 0K - 763 16,32,64 > > tidhash 1 8K - 1 > > callout 7 1792K - 7 > > umtx 750 71K - 750 64,128 > > p1003.1b 1 1K - 1 16 > > SWAP 2 4373K - 2 64 > > bus-sc 97 417K - 6298 > 16,32,64,128,256,512,1024,2048,4096 > > bus 1382 64K - 9711 16,32,64,128,256,1024 > > devstat 16 33K - 16 16,4096 > > eventhandler 73 4K - 73 32,64,128 > > UART 6 3K - 6 16,256,1024 > > kobj 358 716K - 634 2048 > > Per-cpu 1 1K - 1 16 > > ata_pci 2 1K - 2 32 > > rman 226 13K - 424 16,32,64 > > sbuf 0 0K - 1636 > 16,32,64,128,256,512,1024,2048,4096 > > scsi_da 0 0K - 186 16 > > stack 0 0K - 2 128 > > taskqueue 15 1K - 15 16,64 > > Unitno 14 1K - 5912 16,64 > > iov 0 0K - 1847877 16,64,128,256 > > select 9 1K - 9 64 > > ioctlops 0 0K - 5848 > 16,32,64,128,256,512,1024,2048 > > msg 4 25K - 4 1024,4096 > > sem 4 101K - 4 1024,4096 > > shm 1 12K - 1 > > tty 21 11K - 23 512,2048 > > mbuf_tag 0 0K - 549 32,64 > > shmfd 1 4K - 1 4096 > > pcb 18 79K - 567 > 16,32,64,512,1024,2048,4096 > > soname 3 1K - 16885 16,32,128 > > vfscache 1 512K - 1 > > cl_savebuf 0 0K - 48 32 > > vfs_hash 1 256K - 1 > > acpidev 50 2K - 50 32 > > vnodes 2 1K - 2 128 > > vnodemarker 0 0K - 6497 512 > > mount 94 4K - 197 16,32,64,128,256 > > BPF 10 1K - 10 64 > > ether_multi 21 1K - 24 16,32,64 > > ifaddr 90 17K - 90 16,32,64,128,256,512,2048 > > ifnet 11 11K - 11 64,1024 > > USBdev 35 9K - 35 32,128,1024 > > clone 6 24K - 6 4096 > > arpcom 2 1K - 2 16 > > lltable 23 6K - 23 256 > > USB 66 40K - 69 > 16,32,64,128,256,1024,4096 > > routetbl 29 4K - 245 16,64,128,256 > > igmp 10 2K - 10 128 > > in_multi 1 1K - 1 128 > > sctp_iter 0 0K - 3 256 > > sctp_ifn 2 1K - 2 128 > > sctp_ifa 4 1K - 4 128 > > sctp_vrf 1 1K - 1 64 > > sctp_a_it 0 0K - 3 16 > > hostcache 1 16K - 1 > > syncache 1 72K - 1 > > entropy 1024 64K - 1024 64 > > in6_multi 15 2K - 15 16,256 > > pci_link 16 2K - 16 64,128 > > mld 10 2K - 10 128 > > rpc 2 1K - 2 128 > > audit_evclass 179 3K - 218 16 > > jblocks 2 1K - 2 128 > > savedino 0 0K - 121 256 > > sbdep 0 0K - 464 32 > > jsegdep 1 1K - 6778 32 > > jseg 1 1K - 4558 128 > > jfreefrag 0 0K - 179 64 > > jnewblk 0 0K - 5965 64 > > jremref 0 0K - 317 64 > > jaddref 0 0K - 317 64 > > freedep 0 0K - 9 32 > > freework 1 1K - 268 32,128 > > newdirblk 0 0K - 6 32 > > dirrem 0 0K - 305 64 > > mkdir 0 0K - 12 64 > > diradd 0 0K - 305 64 > > freefile 0 0K - 72 32 > > freeblks 0 0K - 157 128 > > freefrag 0 0K - 179 64 > > indirdep 1 1K - 4235 64 > > newblk 2 65K - 5966 128 > > bmsafemap 2 5K - 4389 128,4096 > > inodedep 2 257K - 4997 256 > > pagedep 1 64K - 51 128 > > ufs_dirhash 8 4K - 24 16,32,64,512 > > ufs_mount 21 390K - 21 256,4096 > > vm_pgdata 2 65K - 2 64 > > UMAHash 1 1K - 1 256 > > acpi_perf 2 1K - 2 256 > > DEVFS1 127 32K - 187 256 > > atkbddev 2 1K - 2 32 > > DEVFS3 141 18K - 223 128,256 > > DEVFS 24 1K - 25 16,64 > > memdesc 1 4K - 1 4096 > > apmdev 1 1K - 1 64 > > io_apic 2 2K - 2 1024 > > pfs_nodes 21 3K - 21 128 > > msi 3 1K - 3 64 > > nexusdev 5 1K - 5 16 > > GEOM 117 19K - 2291 > 16,32,64,128,256,512,1024,2048 > > SCSI SES 2 4K - 2 2048 > > kbdmux 7 18K - 7 16,256,1024,2048 > > mps 22 280K - 24141 > 16,32,64,128,256,512,2048,4096 > > mps_user 0 0K - 662 32,64 > > > > > > ` Kashyap > > > > > -----Original Message----- > > > From: Konstantin Belousov [mailto:kostikbel@gmail.com] > > > Sent: Friday, June 01, 2012 6:14 PM > > > To: Desai, Kashyap > > > Cc: freebsd-scsi@freebsd.org; freebsd-fs@freebsd.org; McConnell, > > > Stephen > > > Subject: Re: Kernel panic in FreeBSD-8.3 from UFS > > > > > > On Fri, Jun 01, 2012 at 05:30:39PM +0530, Desai, Kashyap wrote: > > > > Hi, > > > > > > > > We have seen kernel panic while doing IO along with HBA reset. > > > > This looks to be very rare but not sure if someone can help me to > > > > understand what is a issue here. To me it does not look any issue > > > > with underline Device Driver > > > > > > > > See below back trace. > > > You did not specified the panic message. Was it 'kmem_map too small' > ? > > > > > > Unless HBA driver causes memory leak, this is probably indeed > unrelated. > > > > > > > > > > > > #0 doadump (textdump=3D1) at pcpu.h:244 > > > > 244 pcpu.h: No such file or directory. > > > > in pcpu.h > > > > (kgdb) #0 doadump (textdump=3D1) at pcpu.h:244 > > > > #1 0xc0a1845a in kern_reboot (howto=3D260) > > > > at /usr/src/sys/kern/kern_shutdown.c:442 > > > > #2 0xc0a186f1 in panic (fmt=3DVariable "fmt" is not available. > > > > ) at /usr/src/sys/kern/kern_shutdown.c:607 > > > > #3 0xc0c7ceda in kmem_malloc (map=3D0xc15c808c, size=3D32768, > flags=3D2) > > > > at /usr/src/sys/vm/vm_kern.c:334 > > > > #4 0xc0c708e7 in page_alloc (zone=3D0x0, bytes=3D32768, > > > > pflag=3D0xf19839bf > > > "\002", > > > > wait=3D2) at /usr/src/sys/vm/uma_core.c:994 > > > > #5 0xc0c72fe0 in uma_large_malloc (size=3D32768, wait=3D2) > > > > at /usr/src/sys/vm/uma_core.c:3067 > > > > #6 0xc0a04fac in malloc (size=3D32768, mtp=3D0xc102b808, flags=3D2= ) > > > > at /usr/src/sys/kern/kern_malloc.c:492 > > > > #7 0xc0c42e89 in softdep_disk_io_initiation (bp=3D0xdef881fc) > > > > at /usr/src/sys/ufs/ffs/ffs_softdep.c:10126 > > > > #8 0xc0c5208f in ffs_geom_strategy (bo=3D0xc5fc30ac, bp=3D0xdef881= fc) > > > > at buf.h:411 > > > > #9 0xc0c65a43 in ufs_strategy (ap=3D0xf1983b00) > > > > at /usr/src/sys/ufs/ufs/ufs_vnops.c:2317 > > > > #10 0xc0d6a6dd in VOP_STRATEGY_APV (vop=3D0xc102e4a0, a=3D0xf1983b0= 0) > > > > at vnode_if.c:2171 > > > > #11 0xc0a8d19e in bufstrategy (bo=3D0xc6b901bc, bp=3D0xdef881fc) at > > > > vnode_if.h:940 > > > > #12 0xc0a9352e in bufwrite (bp=3D0xdef881fc) at buf.h:404 > > > > #13 0xc0a8db5c in vfs_bio_awrite (bp=3D0xdef881fc) at buf.h:392 > > > > #14 0xc0c584c5 in ffs_syncvnode (vp=3D0xc6b90110, waitfor=3D1) > > > > at /usr/src/sys/ufs/ffs/ffs_vnops.c:288 > > > > #15 0xc0c58739 in ffs_fsync (ap=3D0xf1983c4c) > > > > at /usr/src/sys/ufs/ffs/ffs_vnops.c:187 > > > > #16 0xc0d69712 in VOP_FSYNC_APV (vop=3D0xc102dfc0, a=3D0xf1983c4c) > > > > at vnode_if.c:1267 > > > > #17 0xc0ab5d49 in sys_fsync (td=3D0xc64ea8a0, uap=3D0xf1983cec) at > > > > vnode_if.h:549 > > > > #18 0xc0d49315 in syscall (frame=3D0xf1983d28) at subr_syscall.c:13= 1 > > > > #19 0xc0d32af1 in Xint0x80_syscall () > > > > at /usr/src/sys/i386/i386/exception.s:266 > > > > #20 0x00000033 in ?? ( > > > > > > > > > > > > To me it looks like UFS is doing something to crash the kernel. > > > > > > You might try to use vmstat -z and vmstat -m on core to see what has > > > used KVA. --_002_B2FD678A64EAAD45B089B123FDFC3ED72B9F6C21A7inbmail01lsic_ Content-Type: application/octet-stream; name="xpt_free_ccb.patch" Content-Description: xpt_free_ccb.patch Content-Disposition: attachment; filename="xpt_free_ccb.patch"; size=372; creation-date="Tue, 05 Jun 2012 12:17:56 GMT"; modification-date="Tue, 05 Jun 2012 17:12:59 GMT" Content-Transfer-Encoding: base64 LS0tIHNjc2kvc2NzaV9hbGwuYwkyMDEyLTAxLTI1IDA2OjQ2OjE3LjAwMDAwMDAwMCArMDUzMAor Kysgc2NzaS9zY3NpX2FsbF9uZXcuYwkyMDEyLTA2LTA2IDAxOjM2OjE2LjAwMDAwMDAwMCArMDUz MApAQCAtMzA1Niw3ICszMDU2LDkgQEAgc2NzaV9jb21tYW5kX3N0cmluZyhzdHJ1Y3QgY2FtX2Rl dmljZSAqZAogCQkJICAgIHNjc2lfY2RiX3N0cmluZyhjc2lvLT5jZGJfaW8uY2RiX2J5dGVzLCBj ZGJfc3RyLAogCQkJCQkgICAgc2l6ZW9mKGNkYl9zdHIpKSk7CiAJfQotCisjaWZkZWYgX0tFUk5F TAorICAgIHhwdF9mcmVlX2NjYigodW5pb24gY2NiKiljZ2QpOworI2VuZGlmIC8qIF9LRVJORUwv IV9LRVJORUwgKi8KIAlyZXR1cm4oMCk7CiB9CiAK --_002_B2FD678A64EAAD45B089B123FDFC3ED72B9F6C21A7inbmail01lsic_-- From owner-freebsd-scsi@FreeBSD.ORG Tue Jun 5 14:01:22 2012 Return-Path: Delivered-To: freebsd-scsi@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8FECE1065676; Tue, 5 Jun 2012 14:01:22 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 96F928FC21; Tue, 5 Jun 2012 14:01:21 +0000 (UTC) Received: from odyssey.starpoint.kiev.ua (alpha-e.starpoint.kiev.ua [212.40.38.101]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id RAA21652; Tue, 05 Jun 2012 17:01:20 +0300 (EEST) (envelope-from avg@FreeBSD.org) Message-ID: <4FCE112F.5030200@FreeBSD.org> Date: Tue, 05 Jun 2012 17:01:19 +0300 From: Andriy Gapon User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:12.0) Gecko/20120503 Thunderbird/12.0.1 MIME-Version: 1.0 To: freebsd-scsi@FreeBSD.org X-Enigmail-Version: 1.5pre Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: Subject: camcontrol inquiry cd0 produces an error X-BeenThere: freebsd-scsi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SCSI subsystem List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 05 Jun 2012 14:01:22 -0000 $ camcontrol inquiry cd0 -v pass3: Removable CD-ROM SCSI-0 device (pass3:ahcich5:0:0:0): INQUIRY. CDB: 12 1 80 0 ff 0 (pass3:ahcich5:0:0:0): CAM status: SCSI Status Error (pass3:ahcich5:0:0:0): SCSI status: Check Condition (pass3:ahcich5:0:0:0): SCSI sense: ILLEGAL REQUEST asc:24,0 (Invalid field in CDB) pass3: 150.000MB/s transfers (SATA 1.x, UDMA5, ATAPI 12bytes, PIO 8192bytes) I seem to recall that I didn't get such an error before. -- Andriy Gapon From owner-freebsd-scsi@FreeBSD.ORG Tue Jun 5 14:08:14 2012 Return-Path: Delivered-To: freebsd-scsi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BCBB1106564A for ; Tue, 5 Jun 2012 14:08:14 +0000 (UTC) (envelope-from mj@feral.com) Received: from ns1.feral.com (ns1.feral.com [192.67.166.1]) by mx1.freebsd.org (Postfix) with ESMTP id 941248FC08 for ; Tue, 5 Jun 2012 14:08:14 +0000 (UTC) Received: from [192.168.135.100] (c-76-126-166-136.hsd1.ca.comcast.net [76.126.166.136]) (authenticated bits=0) by ns1.feral.com (8.14.4/8.14.4) with ESMTP id q55E8738071361 (version=TLSv1/SSLv3 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO) for ; Tue, 5 Jun 2012 07:08:08 -0700 (PDT) (envelope-from mj@feral.com) Message-ID: <4FCE12C2.9050605@feral.com> Date: Tue, 05 Jun 2012 07:08:02 -0700 From: Matthew Jacob Organization: Feral Software User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:12.0) Gecko/20120428 Thunderbird/12.0.1 MIME-Version: 1.0 To: freebsd-scsi@freebsd.org References: <4FCE112F.5030200@FreeBSD.org> In-Reply-To: <4FCE112F.5030200@FreeBSD.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (ns1.feral.com [192.67.166.1]); Tue, 05 Jun 2012 07:08:08 -0700 (PDT) Subject: Re: camcontrol inquiry cd0 produces an error X-BeenThere: freebsd-scsi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: mj@feral.com List-Id: SCSI subsystem List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 05 Jun 2012 14:08:14 -0000 On 6/5/2012 7:01 AM, Andriy Gapon wrote: > $ camcontrol inquiry cd0 -v > pass3: Removable CD-ROM SCSI-0 device > (pass3:ahcich5:0:0:0): INQUIRY. CDB: 12 1 80 0 ff 0 > (pass3:ahcich5:0:0:0): CAM status: SCSI Status Error > (pass3:ahcich5:0:0:0): SCSI status: Check Condition > (pass3:ahcich5:0:0:0): SCSI sense: ILLEGAL REQUEST asc:24,0 (Invalid field in CDB) > pass3: 150.000MB/s transfers (SATA 1.x, UDMA5, ATAPI 12bytes, PIO 8192bytes) > > I seem to recall that I didn't get such an error before. > Yes, asking for a list of extended pages is a lose for ATA. How recently did you notice this and what kernel etc? From owner-freebsd-scsi@FreeBSD.ORG Tue Jun 5 14:09:39 2012 Return-Path: Delivered-To: freebsd-scsi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 316921065674; Tue, 5 Jun 2012 14:09:39 +0000 (UTC) (envelope-from mavbsd@gmail.com) Received: from mail-ee0-f54.google.com (mail-ee0-f54.google.com [74.125.83.54]) by mx1.freebsd.org (Postfix) with ESMTP id 8D8938FC08; Tue, 5 Jun 2012 14:09:38 +0000 (UTC) Received: by eeke49 with SMTP id e49so2129813eek.13 for ; Tue, 05 Jun 2012 07:09:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=v1e5UfewfIaDjf98Ockr4yUcgYJg7rLJxa4amcpxC9Q=; b=s8n/1xyPCQ/qZJLdFmD4CJ4XESMXpXEuR9/b97e/aCP1nKt99zjrpd0g+c5/6fUhXw BXhlRARHD1Ucj+dUzGazUDi8OwBXb/trg/SqMuIkR9l7psChZ8DErRulvpUyPbq1H6Fs H+vIvgoLfjD0eyUpYac94OGIZCYL97hVZPCeyx7kq3Btzqt6i7QGjRC6wls9fTDxdkoG CiODyQ5L9u1uIAuWciqJ3tO+UjWR4nI2khTVlCUebNGOMlzMezRjmQFsOxScVoZr0gh3 Va6/Ldft/HyTqC8JxkVnRq4E/OrxwE6Cbk9GHp3jpNL6JneEV/boR0zdvOCsDotRdqU5 9o8A== Received: by 10.14.98.204 with SMTP id v52mr7489416eef.198.1338905371867; Tue, 05 Jun 2012 07:09:31 -0700 (PDT) Received: from mavbook2.mavhome.dp.ua (pc.mavhome.dp.ua. [212.86.226.226]) by mx.google.com with ESMTPS id n52sm6485151eeh.9.2012.06.05.07.09.30 (version=SSLv3 cipher=OTHER); Tue, 05 Jun 2012 07:09:30 -0700 (PDT) Sender: Alexander Motin Message-ID: <4FCE1317.4060201@FreeBSD.org> Date: Tue, 05 Jun 2012 17:09:27 +0300 From: Alexander Motin User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:10.0.3) Gecko/20120328 Thunderbird/10.0.3 MIME-Version: 1.0 To: Andriy Gapon References: <4FCE112F.5030200@FreeBSD.org> In-Reply-To: <4FCE112F.5030200@FreeBSD.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-scsi@FreeBSD.org Subject: Re: camcontrol inquiry cd0 produces an error X-BeenThere: freebsd-scsi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SCSI subsystem List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 05 Jun 2012 14:09:39 -0000 On 06/05/12 17:01, Andriy Gapon wrote: > $ camcontrol inquiry cd0 -v > pass3: Removable CD-ROM SCSI-0 device > (pass3:ahcich5:0:0:0): INQUIRY. CDB: 12 1 80 0 ff 0 > (pass3:ahcich5:0:0:0): CAM status: SCSI Status Error > (pass3:ahcich5:0:0:0): SCSI status: Check Condition > (pass3:ahcich5:0:0:0): SCSI sense: ILLEGAL REQUEST asc:24,0 (Invalid field in CDB) > pass3: 150.000MB/s transfers (SATA 1.x, UDMA5, ATAPI 12bytes, PIO 8192bytes) > > I seem to recall that I didn't get such an error before. Your device doesn't support reporting of the serial number. May be before you was not using -v option that makes that error visible. -- Alexander Motin From owner-freebsd-scsi@FreeBSD.ORG Tue Jun 5 14:15:51 2012 Return-Path: Delivered-To: freebsd-scsi@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 4FA4F106567D; Tue, 5 Jun 2012 14:15:51 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 699398FC1A; Tue, 5 Jun 2012 14:15:50 +0000 (UTC) Received: from odyssey.starpoint.kiev.ua (alpha-e.starpoint.kiev.ua [212.40.38.101]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id RAA21770; Tue, 05 Jun 2012 17:15:49 +0300 (EEST) (envelope-from avg@FreeBSD.org) Message-ID: <4FCE1494.3050800@FreeBSD.org> Date: Tue, 05 Jun 2012 17:15:48 +0300 From: Andriy Gapon User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:12.0) Gecko/20120503 Thunderbird/12.0.1 MIME-Version: 1.0 To: Alexander Motin References: <4FCE112F.5030200@FreeBSD.org> <4FCE1317.4060201@FreeBSD.org> In-Reply-To: <4FCE1317.4060201@FreeBSD.org> X-Enigmail-Version: 1.5pre Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: freebsd-scsi@FreeBSD.org Subject: Re: camcontrol inquiry cd0 produces an error X-BeenThere: freebsd-scsi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SCSI subsystem List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 05 Jun 2012 14:15:51 -0000 on 05/06/2012 17:09 Alexander Motin said the following: > On 06/05/12 17:01, Andriy Gapon wrote: >> $ camcontrol inquiry cd0 -v >> pass3: Removable CD-ROM SCSI-0 device >> (pass3:ahcich5:0:0:0): INQUIRY. CDB: 12 1 80 0 ff 0 >> (pass3:ahcich5:0:0:0): CAM status: SCSI Status Error >> (pass3:ahcich5:0:0:0): SCSI status: Check Condition >> (pass3:ahcich5:0:0:0): SCSI sense: ILLEGAL REQUEST asc:24,0 (Invalid field in CDB) >> pass3: 150.000MB/s transfers (SATA 1.x, UDMA5, ATAPI 12bytes, PIO 8192bytes) >> >> I seem to recall that I didn't get such an error before. > > Your device doesn't support reporting of the serial number. May be before you was > not using -v option that makes that error visible. > Ah, makes sense, thank you! -- Andriy Gapon From owner-freebsd-scsi@FreeBSD.ORG Wed Jun 6 05:08:59 2012 Return-Path: Delivered-To: scsi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3FF9D1065672 for ; Wed, 6 Jun 2012 05:08:59 +0000 (UTC) (envelope-from info@pokercasinogold.com) Received: from pluto.nswebhost.com (pluto.nswebhost.com [174.132.225.251]) by mx1.freebsd.org (Postfix) with ESMTP id CA1288FC16 for ; Wed, 6 Jun 2012 05:08:58 +0000 (UTC) Received: from [189.149.115.206] (helo=dsl-189-149-115-206-dyn.prod-infinitum.com.mx) by pluto.nswebhost.com with esmtpa (Exim 4.69) (envelope-from ) id 1Sc8U6-00055I-KK for scsi@freebsd.org; Wed, 06 Jun 2012 00:08:56 -0500 From: "5TH CASINO" To: "scsi" Content-Type: multipart/related; boundary="iVhXrgtfTbtgQFuWlHd1KYceNhL7=_SkTO" MIME-Version: 1.0 Organization: 5tH CASINO Date: Wed, 6 Jun 2012 00:08:48 -0500 X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - pluto.nswebhost.com X-AntiAbuse: Original Domain - freebsd.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - pokercasinogold.com Message-Id: <20120606050859.3FF9D1065672@hub.freebsd.org> X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: Subject: Take your BENEFITS at 5th CASINO X-BeenThere: freebsd-scsi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SCSI subsystem List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 06 Jun 2012 05:08:59 -0000 This is a multi-part message in MIME format --iVhXrgtfTbtgQFuWlHd1KYceNhL7=_SkTO Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline =20 Get Your BENEFITS!=20 register at www.5thcasino.com Use PROMOTION CODE: 0reg-wmx003 = =20 5thcasino.com rewards your deposits! With your first deposit we give y= ou an amazing Double Bonus, 150% bonus on your Poker account and a = 100% on your Casino account, up to a maximum of 500 Euro. Deposit a= minimum of 25 Euro we will multiply up your deposit.=20 =20 =20 Earning DOUBLOONS is very easy,You on= ly need to play!=20 No activation, no requirement: by making the first deposit, you are al= ready eligible.Starting your rise to power is easy: with your first de= posit, you automatically join our VIP program and you have the chance = to reach the most prestigious levels, and thus obtain Incredible Bonus= es.=20 =20 =20 =20 LIVE Support 24 Hours To unsubs= cribe click here =20 =20 --iVhXrgtfTbtgQFuWlHd1KYceNhL7=_SkTO-- From owner-freebsd-scsi@FreeBSD.ORG Wed Jun 6 14:05:44 2012 Return-Path: Delivered-To: freebsd-scsi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0FD88106566B; Wed, 6 Jun 2012 14:05:44 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from bigwig.baldwin.cx (bigknife-pt.tunnel.tserv9.chi1.ipv6.he.net [IPv6:2001:470:1f10:75::2]) by mx1.freebsd.org (Postfix) with ESMTP id D4AE88FC1F; Wed, 6 Jun 2012 14:05:43 +0000 (UTC) Received: from jhbbsd.localnet (unknown [209.249.190.124]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 43309B98D; Wed, 6 Jun 2012 10:05:43 -0400 (EDT) From: John Baldwin To: freebsd-fs@freebsd.org Date: Wed, 6 Jun 2012 08:19:05 -0400 User-Agent: KMail/1.13.5 (FreeBSD/8.2-CBSD-20110714-p13; KDE/4.5.5; amd64; ; ) References: <20120601125824.GV2358@deviant.kiev.zoral.com.ua> In-Reply-To: MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-15" Content-Transfer-Encoding: 7bit Message-Id: <201206060819.05864.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (bigwig.baldwin.cx); Wed, 06 Jun 2012 10:05:43 -0400 (EDT) Cc: "Desai, Kashyap" , "Kenneth D. Merry" , "Reddy, Sreekanth" , "freebsd-scsi@freebsd.org" , "McConnell, Stephen" Subject: Re: Kernel panic in FreeBSD-8.3 from UFS X-BeenThere: freebsd-scsi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SCSI subsystem List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 06 Jun 2012 14:05:44 -0000 On Tuesday, June 05, 2012 8:19:05 am Desai, Kashyap wrote: > Hi All, > > We found some potential area of memory leak in CAM layer. > CAM XPT Memory leak is due to following function in scsi/scsi_all.c > > int > scsi_command_string(struct ccb_scsiio *csio, struct sbuf *sb) > > > In above function, CAM layer allocate memory for ccb device as below > if ((cgd = (struct ccb_getdev*)xpt_alloc_ccb_nowait()) == NULL) > > > _But_, unfortunately we never free the allocated memory and we see memory leak of 2K every time when someone is calling > Scsi_command_string from kernel mode. > > > Attached is a proposed patch for this issue. The patch looks correct to me. Can one of the CAM folks (Ken?) review it and commit it? -- John Baldwin From owner-freebsd-scsi@FreeBSD.ORG Wed Jun 6 17:06:42 2012 Return-Path: Delivered-To: freebsd-scsi@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 168471065672; Wed, 6 Jun 2012 17:06:42 +0000 (UTC) (envelope-from ken@kdm.org) Received: from nargothrond.kdm.org (nargothrond.kdm.org [70.56.43.81]) by mx1.freebsd.org (Postfix) with ESMTP id CC4A28FC18; Wed, 6 Jun 2012 17:06:41 +0000 (UTC) Received: from nargothrond.kdm.org (localhost [127.0.0.1]) by nargothrond.kdm.org (8.14.2/8.14.2) with ESMTP id q56H6fXr098454; Wed, 6 Jun 2012 11:06:41 -0600 (MDT) (envelope-from ken@nargothrond.kdm.org) Received: (from ken@localhost) by nargothrond.kdm.org (8.14.2/8.14.2/Submit) id q56H6f3O098453; Wed, 6 Jun 2012 11:06:41 -0600 (MDT) (envelope-from ken) Date: Wed, 6 Jun 2012 11:06:41 -0600 From: "Kenneth D. Merry" To: "Desai, Kashyap" Message-ID: <20120606170640.GA98428@nargothrond.kdm.org> References: <20120601124338.GU2358@deviant.kiev.zoral.com.ua> <20120601125824.GV2358@deviant.kiev.zoral.com.ua> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2i Cc: "freebsd-scsi@freebsd.org" , "freebsd-fs@freebsd.org" , "McConnell, Stephen" , "Reddy, Sreekanth" Subject: Re: Kernel panic in FreeBSD-8.3 from UFS X-BeenThere: freebsd-scsi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SCSI subsystem List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 06 Jun 2012 17:06:42 -0000 On Tue, Jun 05, 2012 at 17:49:05 +0530, Desai, Kashyap wrote: > Hi All, > > We found some potential area of memory leak in CAM layer. > CAM XPT Memory leak is due to following function in scsi/scsi_all.c > > int > scsi_command_string(struct ccb_scsiio *csio, struct sbuf *sb) > > > In above function, CAM layer allocate memory for ccb device as below > if ((cgd = (struct ccb_getdev*)xpt_alloc_ccb_nowait()) == NULL) > > > _But_, unfortunately we never free the allocated memory and we see memory leak of 2K every time when someone is calling > Scsi_command_string from kernel mode. > > > Attached is a proposed patch for this issue. The patch looks good, I just committed it. Thanks! Ken -- Kenneth Merry ken@FreeBSD.ORG From owner-freebsd-scsi@FreeBSD.ORG Fri Jun 8 06:35:09 2012 Return-Path: Delivered-To: freebsd-scsi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id ECB00106564A; Fri, 8 Jun 2012 06:35:09 +0000 (UTC) (envelope-from bryanv@daemoninthecloset.org) Received: from torment.daemoninthecloset.org (torment.daemoninthecloset.org [94.242.209.234]) by mx1.freebsd.org (Postfix) with ESMTP id A9ECE8FC12; Fri, 8 Jun 2012 06:35:09 +0000 (UTC) X-Virus-Scanned: amavisd-new at daemoninthecloset.org Received: from sage.daemoninthecloset.org (sage.daemoninthecloset.org [127.0.1.1]) by sage.daemoninthecloset.org (Postfix) with ESMTP id 04C93748C; Fri, 8 Jun 2012 01:29:19 -0500 (CDT) Date: Fri, 8 Jun 2012 01:29:18 -0500 (CDT) From: Bryan Venteicher To: freebsd-scsi@freebsd.org Message-ID: <608701174.2086.1339136958852.JavaMail.root@sage.daemoninthecloset.org> In-Reply-To: <1703316164.2068.1339136456040.JavaMail.root@sage.daemoninthecloset.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Originating-IP: [192.168.10.20] X-Mailer: Zimbra 7.1.4_GA_2555 (ZimbraWebClient - GC19 ([unknown])/7.1.4_GA_2555) Cc: freebsd-virtualization@freebsd.org Subject: [CFT] VirtIO SCSI Driver X-BeenThere: freebsd-scsi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SCSI subsystem List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 08 Jun 2012 06:35:10 -0000 Hi, VirtIO SCSI is a virtualized HBA that offers a couple of advantages over the existing VirtIO block disk devices. Instead of having a vtbdX disk, familiar daX and cdX devices are created like from other SCSI drivers. A single HBA is able to support multiple devices unlike the VirtIO block where there is one disk per PCI device. And SCSI devices from the host are able to be passthrough to the guest. VirtIO SCSI is relatively new - I think the Linux guest driver first came out as part of the 3.4 kernel from last month - and as a result you need a relatively new QEMU (post-February of this year). Various minor bits of the spec do not seem to be supported by QEMU yet (like event monitoring), but there is stub code in the driver for when support is added. Patch is available at: www.daemoninthecloset.org/~bryanv/patches/freebsd/freebsd_virtio_scsi_1.patch Should apply cleanly to any recent -current, and probably to a -stable with minimal work. From owner-freebsd-scsi@FreeBSD.ORG Fri Jun 8 21:25:38 2012 Return-Path: Delivered-To: freebsd-scsi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 19A92106564A for ; Fri, 8 Jun 2012 21:25:38 +0000 (UTC) (envelope-from dustinwenz@ebureau.com) Received: from internet02.ebureau.com (internet02.tru-signal.biz [65.127.24.21]) by mx1.freebsd.org (Postfix) with ESMTP id D0AFA8FC14 for ; Fri, 8 Jun 2012 21:25:37 +0000 (UTC) Received: from service02.office.ebureau.com (service02.office.ebureau.com [192.168.20.15]) by internet02.ebureau.com (Postfix) with ESMTP id 9CF55CA2AF1 for ; Fri, 8 Jun 2012 16:25:31 -0500 (CDT) Received: from localhost (localhost [127.0.0.1]) by service02.office.ebureau.com (Postfix) with ESMTP id 82C9C9E1D27E for ; Fri, 8 Jun 2012 16:25:31 -0500 (CDT) X-Virus-Scanned: amavisd-new at ebureau.com Received: from service02.office.ebureau.com ([127.0.0.1]) by localhost (service02.office.iscompanies.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id mvy5cWgOQrp6 for ; Fri, 8 Jun 2012 16:25:31 -0500 (CDT) Received: from square.office.iscompanies.com (square.office.iscompanies.com [10.10.20.22]) by service02.office.ebureau.com (Postfix) with ESMTPSA id 247A79E1D26F for ; Fri, 8 Jun 2012 16:25:31 -0500 (CDT) From: Dustin Wenz Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Date: Fri, 8 Jun 2012 16:25:31 -0500 Message-Id: <60F17E0E-EE4A-4F37-9925-055315B987B1@ebureau.com> To: freebsd-scsi@freebsd.org Mime-Version: 1.0 (Apple Message framework v1257) X-Mailer: Apple Mail (2.1257) Subject: Marginal disks prevent boot with mps(4) X-BeenThere: freebsd-scsi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SCSI subsystem List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 08 Jun 2012 21:25:38 -0000 I just installed a build of 9.0-STABLE in order to test the changes = since release. I was hoping that some of the error-handling in mps would = alter the behavior I've seen with some SATA disks (particularly, Seagate = ST3000DM001 disks) connected through an LSI SAS 9201-16e HBA. It is apparently possible for these disks to get in a state where their = presence prevents the machine from booting. This problem has existed for = some time, according to some archive-searching I've done, but there = isn't much consensus on how to fix it. The disks are good enough that they can be probed at startup, but some = part of initialization cannot complete. This is the message I see = repeated forever upon boot (the probe number does change slightly): (probe14:mps0:0:14:0): INQUIRY. CDB: 12 0 0 0 24 0 length 36 = SMID 215 terminated ioc 804b scsi 0 state c xfer 0 There is a comment in mps_sas.c which suggests that this error is = usually transient, but that seems not to be the case here. Can anyone = suggest a modification that might permit booting in this state? - .Dustin From owner-freebsd-scsi@FreeBSD.ORG Fri Jun 8 21:53:33 2012 Return-Path: Delivered-To: freebsd-scsi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E25A81065670 for ; Fri, 8 Jun 2012 21:53:33 +0000 (UTC) (envelope-from ken@kdm.org) Received: from nargothrond.kdm.org (nargothrond.kdm.org [70.56.43.81]) by mx1.freebsd.org (Postfix) with ESMTP id 912C68FC08 for ; Fri, 8 Jun 2012 21:53:33 +0000 (UTC) Received: from nargothrond.kdm.org (localhost [127.0.0.1]) by nargothrond.kdm.org (8.14.2/8.14.2) with ESMTP id q58LrQj9084946; Fri, 8 Jun 2012 15:53:26 -0600 (MDT) (envelope-from ken@nargothrond.kdm.org) Received: (from ken@localhost) by nargothrond.kdm.org (8.14.2/8.14.2/Submit) id q58LrQV1084945; Fri, 8 Jun 2012 15:53:26 -0600 (MDT) (envelope-from ken) Date: Fri, 8 Jun 2012 15:53:26 -0600 From: "Kenneth D. Merry" To: Dustin Wenz Message-ID: <20120608215326.GA83721@nargothrond.kdm.org> References: <60F17E0E-EE4A-4F37-9925-055315B987B1@ebureau.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <60F17E0E-EE4A-4F37-9925-055315B987B1@ebureau.com> User-Agent: Mutt/1.4.2i Cc: freebsd-scsi@freebsd.org Subject: Re: Marginal disks prevent boot with mps(4) X-BeenThere: freebsd-scsi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SCSI subsystem List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 08 Jun 2012 21:53:34 -0000 On Fri, Jun 08, 2012 at 16:25:31 -0500, Dustin Wenz wrote: > I just installed a build of 9.0-STABLE in order to test the changes since release. I was hoping that some of the error-handling in mps would alter the behavior I've seen with some SATA disks (particularly, Seagate ST3000DM001 disks) connected through an LSI SAS 9201-16e HBA. > Are you using an expander, or are the disks connected directly to the HBA? What firmware version are you using on the HBA? Make sure you have the latest firmware version on the card. > It is apparently possible for these disks to get in a state where their presence prevents the machine from booting. This problem has existed for some time, according to some archive-searching I've done, but there isn't much consensus on how to fix it. > > The disks are good enough that they can be probed at startup, but some part of initialization cannot complete. This is the message I see repeated forever upon boot (the probe number does change slightly): > > (probe14:mps0:0:14:0): INQUIRY. CDB: 12 0 0 0 24 0 length 36 SMID 215 terminated ioc 804b scsi 0 state c xfer 0 > > There is a comment in mps_sas.c which suggests that this error is usually transient, but that seems not to be the case here. Can anyone suggest a modification that might permit booting in this state? > There is not a lot that the driver can do in this case. The command is getting terminated by the firmware in the HBA, and we really don't have a lot of information to indicate why. You could change the status returned for MPI2_IOCSTATUS_SCSI_IOC_TERMINATED to CAM_REQ_CMP_ERR, and that would just mean that the probe for that disk would eventually fail and the kernel would boot. CAM_REQUEUE_REQ tells CAM to retry the command without decrementing the retry count. That is why you aren't able to boot. If upgrading the HBA firmware doesn't fix the problem, I would suggest contacting LSI support, and see if they can get additional diagnostics off the board to figure out what the problem is. Ken -- Kenneth Merry ken@FreeBSD.ORG From owner-freebsd-scsi@FreeBSD.ORG Sat Jun 9 04:39:42 2012 Return-Path: Delivered-To: freebsd-scsi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 8FC2C106564A for ; Sat, 9 Jun 2012 04:39:42 +0000 (UTC) (envelope-from kcreyts@merit.edu) Received: from sfpop-ironport03.merit.edu (sfpop-ironport03.merit.edu [207.75.116.62]) by mx1.freebsd.org (Postfix) with ESMTP id 583328FC14 for ; Sat, 9 Jun 2012 04:39:42 +0000 (UTC) X-Merit-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.75,741,1330923600"; d="scan'208";a="294778108" Received: from merit-mailstore01.merit.edu ([10.108.1.190]) by sfpop-ironport03-ob.merit.edu with ESMTP; 09 Jun 2012 00:38:34 -0400 Date: Sat, 9 Jun 2012 00:38:34 -0400 (EDT) Message-ID: From: Kyle Creyts To: Dustin Wenz , freebsd-scsi@freebsd.org MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=UTF-8 X-Mailer: Zimbra 7.2.0_GA_2669 (MobileSync - Android/0.3) Cc: Subject: Re: Marginal disks prevent boot with mps(4) X-BeenThere: freebsd-scsi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SCSI subsystem List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 09 Jun 2012 04:39:42 -0000 Pop the offending disk out, then back in after boot. Consider replacing. Dustin Wenz wrote: I just installed a build of 9.0-STABLE in order to test the changes since release. I was hoping that some of the error-handling in mps would alter the behavior I've seen with some SATA disks (particularly, Seagate ST3000DM001 disks) connected through an LSI SAS 9201-16e HBA. It is apparently possible for these disks to get in a state where their presence prevents the machine from booting. This problem has existed for some time, according to some archive-searching I've done, but there isn't much consensus on how to fix it. The disks are good enough that they can be probed at startup, but some part of initialization cannot complete. This is the message I see repeated forever upon boot (the probe number does change slightly): (probe14:mps0:0:14:0): INQUIRY. CDB: 12 0 0 0 24 0 length 36 SMID 215 terminated ioc 804b scsi 0 state c xfer 0 There is a comment in mps_sas.c which suggests that this error is usually transient, but that seems not to be the case here. Can anyone suggest a modification that might permit booting in this state? - .Dustin _______________________________________________ freebsd-scsi@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-scsi To unsubscribe, send any mail to "freebsd-scsi-unsubscribe@freebsd.org"