Re: realtek 8179 wireless pci

2016-08-14 Thread Prabhu Gurumurthy
Hello Stefan, Thank you, will try to do that and let you know how it goes. I see NetBSD mention some about RT8188EE in their code, but nothing major, just in pcidevs and pcidevs.h in src/sys/dev/pci. I am also about to start looking for it in FreeBSD, prior to installing Linux on the system. Tha

reduce qabs() and qdiv() to aliases and deprecate them in manual

2016-08-14 Thread Philip Guenther
strtoq() and strtouq() are already provided as just aliases of strtoll() and strotull(); let's do the same with qabs() and qdiv() instead of having them as fully separate functions. Similarly, they don't need separate manpages, so roll them into the same manpages as llabs(3) and lldiv(3), call

eliminate uses of strtoq/strtouq

2016-08-14 Thread Philip Guenther
This replaces all the calls to strtoq() and strtouq() in base (outside gnu/) with calls to stroll/stroull. In those files, update types, use of %q and QUAD_MAX as well. While here, fix a bug in ftp: the 'page' command tries to save and restore the restart position...but saved it in an int ins

Re: csh: don't reinvent rlim_t

2016-08-14 Thread Martin Natano
On Sat, Aug 13, 2016 at 11:41:26PM -0700, Philip Guenther wrote: > > This seems unnecessary: > typedef quad_t RLIM_TYPE; > > when we have rlim_t. Yes, rlim_t is unsigned while RLIM_TYPE is signed, > but it's not doing anything with this that needs a signed type. > > While ktracing csh to

Re: reduce qabs() and qdiv() to aliases and deprecate them in manual

2016-08-14 Thread Martin Natano
On Sun, Aug 14, 2016 at 12:25:18AM -0700, Philip Guenther wrote: > > strtoq() and strtouq() are already provided as just aliases of strtoll() > and strotull(); let's do the same with qabs() and qdiv() instead of having > them as fully separate functions. > > Similarly, they don't need separate

Re: eliminate uses of strtoq/strtouq

2016-08-14 Thread Martin Natano
> Index: usr.sbin/mtree/spec.c > === > RCS file: /data/src/openbsd/src/usr.sbin/mtree/spec.c,v > retrieving revision 1.26 > diff -u -p -r1.26 spec.c > --- usr.sbin/mtree/spec.c 8 Jul 2012 21:19:42 - 1.26 > +++ usr.sbin/mt

replace the last uses of m_copym2 with m_dup_pkt

2016-08-14 Thread David Gwynne
then i can delete it. ok? Index: net/pfkey.c === RCS file: /cvs/src/sys/net/pfkey.c,v retrieving revision 1.29 diff -u -p -r1.29 pfkey.c --- net/pfkey.c 22 Mar 2016 11:53:21 - 1.29 +++ net/pfkey.c 14 Aug 2016 09:44:20 -

Re: Make Cortex-A7 go fast

2016-08-14 Thread Mark Kettenis
> Date: Sun, 14 Aug 2016 14:48:59 +1000 > From: Jonathan Gray > > On Sat, Aug 13, 2016 at 08:26:30PM +0200, Mark Kettenis wrote: > > On Cortex-A7 there is a magic SMP bit in the Auxiliary Control > > Register that "Enables coherent requests to the processor". The > > Cortex-A7 Technical Referenc

Two sunxi driver diffs

2016-08-14 Thread Mark Kettenis
Here are two diffs for the sunxi armv7 platform that I can't test myself. The first one is for sxiahci(4), and changes it to use the regulator API to power on the bus. The second one is for sxie(4), and changes it to use the pinctrl API to select the appropriate pins. If anybody with a Allwinner

Re: sixuart fifo fix

2016-08-14 Thread Marcus Glocker
On Sun, Aug 14, 2016 at 12:08:14AM +0200, Mark Kettenis wrote: > > Date: Sat, 13 Aug 2016 23:06:45 +0200 > > From: Marcus Glocker > > > > When I currently boot the allwinner,sun5i-r8 board with an UART cable > > connected for console but no terminal attached, the boot hangs as soon > > the drive

Re: Make Cortex-A7 go fast

2016-08-14 Thread Jonathan Gray
On Sun, Aug 14, 2016 at 01:20:04PM +0200, Mark Kettenis wrote: > > Date: Sun, 14 Aug 2016 14:48:59 +1000 > > From: Jonathan Gray > > > > On Sat, Aug 13, 2016 at 08:26:30PM +0200, Mark Kettenis wrote: > > > On Cortex-A7 there is a magic SMP bit in the Auxiliary Control > > > Register that "Enables

fuse: fh functions must die

2016-08-14 Thread Martin Natano
After staring a couple of days at fusefs and libfuse code I came to the conclusion, that the fuse_vptofh() and fuse_fhtovp() functions must die. I implemented those functions under the assumption, that fuse_vget() has reasonable semantics, while this is not the case. fusefs_vget() only functions co

imxtemp(4), a temperature sensor for i.MX6

2016-08-14 Thread Mark Kettenis
Based on the code from patrick@ in bitrig. ok? Index: arch/armv7/conf/GENERIC === RCS file: /cvs/src/sys/arch/armv7/conf/GENERIC,v retrieving revision 1.46 diff -u -p -r1.46 GENERIC --- arch/armv7/conf/GENERIC 13 Aug 2016 22:07:0

Re: imxtemp(4), a temperature sensor for i.MX6

2016-08-14 Thread Theo de Raadt
I am concerned with having a 25 x delay(1) in the refresh. Is possible to do the measurement startup -- then schedule a task to pick up the results? > +void > +imxtemp_refresh_sensors(void *arg) > +{ > + struct imxtemp_softc *sc = (struct imxtemp_softc *)arg; > + uint32_t value; > + u

Re: imxtemp(4), a temperature sensor for i.MX6

2016-08-14 Thread Mark Kettenis
> From: "Theo de Raadt" > Date: Sun, 14 Aug 2016 10:51:19 -0600 > > I am concerned with having a 25 x delay(1) in the refresh. > > Is possible to do the measurement startup -- then schedule a task > to pick up the results? I'm not too worried. There are worse offenders in the tree ;). But sin

Re: csh: don't reinvent rlim_t

2016-08-14 Thread Philip Guenther
On Sun, Aug 14, 2016 at 1:26 AM, Martin Natano wrote: > On Sat, Aug 13, 2016 at 11:41:26PM -0700, Philip Guenther wrote: ... >> @@ -1124,14 +1122,14 @@ getval(struct limits *lp, Char **v) >> cp++; >> if (*cp == 0) { >> if (*v == 0) >> - return ((RLIM_TYPE) ((f + 0.5) * lp-

Re: fuse: fh functions must die

2016-08-14 Thread Philip Guenther
On Sun, Aug 14, 2016 at 7:57 AM, Martin Natano wrote: > After staring a couple of days at fusefs and libfuse code I came to the > conclusion, that the fuse_vptofh() and fuse_fhtovp() functions must die. > I implemented those functions under the assumption, that fuse_vget() has > reasonable semanti

Re: csh: don't reinvent rlim_t

2016-08-14 Thread Martin Natano
On Sun, Aug 14, 2016 at 11:49:00AM -0700, Philip Guenther wrote: > On Sun, Aug 14, 2016 at 1:26 AM, Martin Natano wrote: > > On Sat, Aug 13, 2016 at 11:41:26PM -0700, Philip Guenther wrote: > ... > >> @@ -1124,14 +1122,14 @@ getval(struct limits *lp, Char **v) > >> cp++; > >> if (*cp ==

bin/*: the last %q bits

2016-08-14 Thread Philip Guenther
ok? Index: bin/dd/misc.c === RCS file: /cvs/src/bin/dd/misc.c,v retrieving revision 1.18 diff -u -p -r1.18 misc.c --- bin/dd/misc.c 12 Feb 2014 01:18:36 - 1.18 +++ bin/dd/misc.c 14 Aug 2016 20:57:33 - @@ -90,

fsirand: kill %q and some unnecessary casts

2016-08-14 Thread Philip Guenther
Don't cast to void* for the 2nd argument to read() and write(). Only cast to off_t for the 2nd argument to lseek() when it's just a value. *Do* cast just one operand of * to make sure the math is done in the bigger type. ok? Index: sbin/fsirand//fsirand.c ==

pstat and vmstat: quad_t and %q

2016-08-14 Thread Philip Guenther
...and replace a lint ARGUSED with __unused ok? Index: usr.bin/vmstat/vmstat.c === RCS file: /cvs/src/usr.bin/vmstat/vmstat.c,v retrieving revision 1.140 diff -u -p -r1.140 vmstat.c --- usr.bin/vmstat/vmstat.c 27 Jul 2016 14:44:

sysctl: quad cleanup

2016-08-14 Thread Philip Guenther
I'm going to preemptively state that CTLTYPE_QUAD now implies int64_t instead of quad_t. So, with that understood, the diff below should make sense. Note that the variable quadval is actually of type int64_t. Oh, and use memcpy() instead of up-casting from char* to (long long*). ok? Index:

ftpd: quad and more

2016-08-14 Thread Philip Guenther
- s/%q/%ll - cast off_t to long long for printf() - delete pointless casts to off_t, void*, and uid_t when that's the argument's type - s/0L/0/ - when casting to a larger type for multiplication, cast *before* multiplying! Wrong: (off_t)(x * y)Right: (off_t)x * y ok? Index: libexec/f

Re: Add / Amend history info for some utilities in /bin

2016-08-14 Thread Sevan Janiyan
On 12/08/2016 05:21, Sevan Janiyan wrote: > Hello, > Attached diff adds history sections to chio(1), dd(1), echo(1), pax(1), > sleep(1) and test(1). > > Corrects the version info in sync(8). > > Ammends kill(1) to note originally the command appeared in section eight. > > Info obtained from th

Re: sixuart fifo fix

2016-08-14 Thread Mark Kettenis
> Date: Sun, 14 Aug 2016 14:02:21 +0200 > From: Marcus Glocker > > On Sun, Aug 14, 2016 at 12:08:14AM +0200, Mark Kettenis wrote: > > > > Date: Sat, 13 Aug 2016 23:06:45 +0200 > > > From: Marcus Glocker > > > > > > When I currently boot the allwinner,sun5i-r8 board with an UART cable > > > con

a few userspace quad_t conversions

2016-08-14 Thread Philip Guenther
du is an easy on, though the use of fts_number here reminded me that we need to increase to a long long at some point like the other BSDs did. hexdump is...subtle, as it both creates format strings on the fly and *rewrites* them! Turns out it was using %q for both of those, hah! The display.

Re: Correct order of route removal

2016-08-14 Thread Martin Pieuchot
On 08/08/16(Mon) 11:48, Martin Pieuchot wrote: > The rtable_walk() & prio bug I just sent a fix for should theoretically > not cause any trouble. Sadly it is piled on top of another bug for > which a fix is attached. > > When an interface is removed the current code starts by purging all its > co

Re: rtable_walk() hand and route prio

2016-08-14 Thread Martin Pieuchot
On 08/08/16(Mon) 11:42, Martin Pieuchot wrote: > On the train back from n2k16 I found the real cause of the hang reported > by Dimitris Papastamos [0] and exposed by our recent > changes to the routing table. > > When an interface is removed/detached the kernel delete all the > corresponding route

Re: a few userspace quad_t conversions

2016-08-14 Thread Martin Natano
On Sun, Aug 14, 2016 at 09:59:21PM -0700, Philip Guenther wrote: > > du is an easy on, though the use of fts_number here reminded me that we > need to increase to a long long at some point like the other BSDs did. > > hexdump is...subtle, as it both creates format strings on the fly and > *rewr