Date: Mon, 3 Sep 2012 10:20:52 -0300 From: Luiz Otavio O Souza <loos.br@gmail.com> To: Warner Losh <imp@bsdimp.com> Cc: freebsd-arch@freebsd.org Subject: Re: spibus access serialization Message-ID: <6AAF2B85-B720-45B5-8F92-FBD9F49F1E6F@gmail.com> In-Reply-To: <99A4DDAC-7A6E-4FA5-B55A-5C30210D9981@bsdimp.com> References: <B54C4C9A-76F4-45CC-94C3-628DDF901051@gmail.com> <99A4DDAC-7A6E-4FA5-B55A-5C30210D9981@bsdimp.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sep 2, 2012, at 4:50 PM, Warner Losh wrote: >=20 > On Sep 2, 2012, at 6:37 AM, Luiz Otavio O Souza wrote: >=20 >> <spibus-01.diff> >=20 > This looks good to me as is. >=20 > spibus-02.diff >=20 > This looks good as well. There's another change mixed in = (DEVMETHOD_END), but it is likely benign enough to go in with this. If = you really want, split it out, but if you don't really want, things are = OK as is. >=20 > spibus-03.diff >=20 > + mtx_sleep(sc, &sc->sc_mtx, 0, "ar71xx_spi", 0); >=20 > I'm not sure I see what wakes this up. Am I missing something? Same = is true in all the drivers. The rest is decent enough, but does mean we = can only do acquire/release in a sleepable context. Is that going to be = OK? No, you're right, the patch is incomplete (my bad) :-/ For now doing the acquire/release only on sleepable context isn't = causing any problems, do you think i should change this ? I'll update the patch and do some more work to move some of common code = to default methods or to spibus code as suggested by ray@. Thanks for the review! Luiz=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?6AAF2B85-B720-45B5-8F92-FBD9F49F1E6F>