Date: Sat, 1 May 2010 20:28:20 +0400 From: pluknet <pluknet@gmail.com> To: Marius Strobl <marius@alchemy.franken.de> Cc: freebsd-scsi <freebsd-scsi@freebsd.org>, FreeBSD Current <freebsd-current@freebsd.org>, Matthew Jacob <mj@feral.com> Subject: Re: mpt(4) MPI_EVENT_IR_RESYNC_UPDATE Message-ID: <l2qa31046fc1005010928m9435861s74dbfd735394ba88@mail.gmail.com> In-Reply-To: <20100501150331.GA74398@alchemy.franken.de> References: <x2oa31046fc1004300536t650346afkb194ca4e2f7a7b1@mail.gmail.com> <4BDAE7BD.4000503@feral.com> <y2ka31046fc1004300750t38a97fbavbd3e6b9326e65904@mail.gmail.com> <20100501150331.GA74398@alchemy.franken.de>
next in thread | previous in thread | raw e-mail | index | archive | help
On 1 May 2010 19:03, Marius Strobl <marius@alchemy.franken.de> wrote: > On Fri, Apr 30, 2010 at 06:50:26PM +0400, pluknet wrote: >> On 30 April 2010 18:22, Matthew Jacob <mj@feral.com> wrote: >> > pluknet wrote: >> > Seems good to me- why not trhow it freebsd-scsi? if nobody says no, I'= ll put >> > it in >> >> Err.. I thought that list is dedicated for cam related stuff. >> >> [cc'ing scsi@ for better coverage. Sorry for cross-posting :/ ] >> >> > >> >> --- RELENG_7_3/src/sys/dev/mpt/mpt_cam.c =A0 =A0 =A0 =A02010-03-02 >> >> 15:38:13.000000000 +0300 >> >> +++ RELENG_7_3.ours/src/sys/dev/mpt/mpt_cam.c =A0 2010-04-21 >> >> 19:31:00.000000000 +0400 >> >> @@ -2564,6 +2564,12 @@ mpt_cam_event(struct mpt_softc *mpt, req >> >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0CAMLOCK_2_MPTLOCK(mpt); >> >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0break; >> >> =A0 =A0 =A0 =A0} >> >> + =A0 =A0 =A0 case MPI_EVENT_IR_RESYNC_UPDATE: >> >> + =A0 =A0 =A0 { >> >> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 uint8_t resync =3D (data0 >> 16) & 0xff= ; >> >> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 mpt_prt(mpt, "IR resync update %d compl= eted\n", resync); >> >> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 break; >> >> + =A0 =A0 =A0 } >> >> =A0 =A0 =A0 =A0case MPI_EVENT_EVENT_CHANGE: >> >> =A0 =A0 =A0 =A0case MPI_EVENT_INTEGRATED_RAID: >> >> =A0 =A0 =A0 =A0case MPI_EVENT_SAS_DEVICE_STATUS_CHANGE: >> >> >> >> Another way - just hide such event since mptutil displays rebuild >> >> progress. >> >> >> >> >> > > Could you maybe avoid defining a variable inside a nested scope for > consistency with the majority of the existing cases and in order to > not violate style(9) unnecessarily? > > Marius > > Index: mpt_cam.c > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > --- mpt_cam.c =A0 (revision 207463) > +++ mpt_cam.c =A0 (working copy) > @@ -2575,6 +2575,10 @@ mpt_cam_event(struct mpt_softc *mpt, request_t *re > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0CAMLOCK_2_MPTLOCK(mpt); > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0break; > =A0 =A0 =A0 =A0} > + =A0 =A0 =A0 case MPI_EVENT_IR_RESYNC_UPDATE: > + =A0 =A0 =A0 =A0 =A0 =A0 =A0 mpt_prt(mpt, "IR resync update %d completed= \n", > + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 (data0 >> 16) & 0xff); > + =A0 =A0 =A0 =A0 =A0 =A0 =A0 break; > =A0 =A0 =A0 =A0case MPI_EVENT_EVENT_CHANGE: > =A0 =A0 =A0 =A0case MPI_EVENT_INTEGRATED_RAID: > =A0 =A0 =A0 =A0case MPI_EVENT_SAS_DEVICE_STATUS_CHANGE: > I'm fine with it, resync variable is not necessary there. Thanks for review. --=20 wbr, pluknet
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?l2qa31046fc1005010928m9435861s74dbfd735394ba88>