Date: Wed, 1 Apr 2015 14:02:29 +0200 From: Mateusz Guzik <mjguzik@gmail.com> To: Gleb Smirnoff <glebius@FreeBSD.org> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r280955 - in head/sys: modules/notrandom dev/notrandom Message-ID: <20150401120229.GA2201@dft-labs.eu> In-Reply-To: <20150401115729.GA64665@FreeBSD.org> References: <20150401113628.GA16649@dft-labs.eu> <20150401114313.GZ64665@FreeBSD.org> <20150401115204.GB16649@dft-labs.eu> <20150401115729.GA64665@FreeBSD.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, Apr 01, 2015 at 02:57:29PM +0300, Gleb Smirnoff wrote: > On Wed, Apr 01, 2015 at 01:52:04PM +0200, Mateusz Guzik wrote: > M> /dev/zero returns 0s, while notrandom was implemented to return 7s. > M> > M> We could e.g. symlink /dev/notrandom to /dev/zero, but that would break > M> compatiblity with Solaris apps depending on this functionality. > M> > M> It could also introduce hard-to-debug problems. After all, readers get a > M> different value than they expect. > M> > M> Given that we have some parts of Solaris merged (zfs, dtrace) and work > M> with open source forks on these technologies, I think we should diverge > M> only when necessary. > M> > M> As a side note I'm surprised with the choice of 7. > M> > M> I would expect 3, no more, no less. 3 would be the number returned, and > M> the number readers receive would be 3. > > You can add the seven_region variable to dev/null/null.c and implement > the new device here. Now notrandom.c shares > 50% of code with null.c. > Yeah I know, in fact I got most of the code from that driver. I just wanted to have a file with my own copyright in the tree, what's so bad about it. If you feel strongly about it feel free to move it, but I would prefer if you did not. -- Mateusz Guzik <mjguzik gmail.com>
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20150401120229.GA2201>