growfs fix

2014-04-29 Thread Kenneth R Westerback
This seems to fix growfs on 4k-sector drives by doing the test write to the last sector rather than the last 512-byte block, which can't be accessed directly on 4k-sector drives. Any other growfs users out there want to test on 'normal' drives? Ken Index: growfs.c

Re: [PATCH?] Variable assignments...

2013-06-24 Thread Kenneth R Westerback
On Mon, Jun 24, 2013 at 06:15:44PM +0200, Maxime Villard wrote: Hi, there are lots of useless assignment of variables in the code. I know this kind of things does not really matter, but when I run my code scanner on some parts of the source tree it gives me lots of them. For example, for

Re: exec_elf.c: mistake ?

2013-07-06 Thread Kenneth R Westerback
On Sat, Jul 06, 2013 at 05:21:31PM +0200, Maxime Villard wrote: Hi, - - - - sys/kern/exec_elf.c l.236 ~ 251252 Are my code scanner and me wrong, or 'bdiff' may not be initialized ? Codewise it does look possible that bdiff will be used uninitialized. Whether it can happen in reality depends

Re: ldconfig/prebind.c - remove dead assignments

2013-07-14 Thread Kenneth R Westerback
On Sun, Jul 14, 2013 at 09:23:53AM +0200, J??r??mie Courr??ges-Anglas wrote: David Hill dh...@mindcry.org writes: remove unused variables. Makes sense. ok? Index: ldconfig/prebind.c === RCS file:

Re: ldd.c - plug memleak

2013-07-14 Thread Kenneth R Westerback
On Sun, Jul 14, 2013 at 09:23:05AM +0200, J??r??mie Courr??ges-Anglas wrote: David Hill dh...@mindcry.org writes: Hello - Hi, doit() was not free()'ing memory or close()'ing the file descriptor if realpath() failed or dlopen() returned NULL. This diff just moves close() and

Re: ldconfig/prebind.c - remove dead assignments

2013-07-14 Thread Kenneth R Westerback
On Sun, Jul 14, 2013 at 03:13:32PM +0200, J??r??mie Courr??ges-Anglas wrote: Kenneth R Westerback kwesterb...@rogers.com writes: On Sun, Jul 14, 2013 at 09:23:53AM +0200, J??r??mie Courr??ges-Anglas wrote: David Hill dh...@mindcry.org writes: remove unused variables. Makes sense

Re: ldconfig/prebind.c - remove dead assignments

2013-07-14 Thread Kenneth R Westerback
On Sun, Jul 14, 2013 at 05:56:46PM +0200, J??r??mie Courr??ges-Anglas wrote: Kenneth R Westerback kwesterb...@rogers.com writes: On Sun, Jul 14, 2013 at 03:13:32PM +0200, J??r??mie Courr??ges-Anglas wrote: Kenneth R Westerback kwesterb...@rogers.com writes: On Sun, Jul 14, 2013 at 09

Re: ldconfig/prebind.c - remove dead assignments

2013-07-14 Thread Kenneth R Westerback
On Sun, Jul 14, 2013 at 08:22:45PM +0200, J??r??mie Courr??ges-Anglas wrote: Kenneth R Westerback kwesterb...@rogers.com writes: On Sun, Jul 14, 2013 at 05:56:46PM +0200, J??r??mie Courr??ges-Anglas wrote: Kenneth R Westerback kwesterb...@rogers.com writes: On Sun, Jul 14, 2013 at 03

Re: Remove unused argument from *rtrequest()

2013-08-27 Thread Kenneth R Westerback
On Tue, Aug 27, 2013 at 03:58:51PM +0200, Martin Pieuchot wrote: In order to define a proper API for our routine table, I'd like to turn the struct rt_addrinfo into a private type (ie: only used in route.c and rtsock.c). This type is used by a lost of code in our network stack to add or

Re: defer routing table updates on link state changes

2013-08-27 Thread Kenneth R Westerback
On Tue, Aug 27, 2013 at 01:54:34PM +0200, Mike Belopuhov wrote: On 27 August 2013 13:39, Martin Pieuchot mpieuc...@nolizard.org wrote: I think that's the right approach but the current code generating interfaces indexes is too clever from my point of view, it tries to reuse the last index

Re: Split rtinit()

2013-08-27 Thread Kenneth R Westerback
On Tue, Aug 27, 2013 at 03:38:49PM +0200, Martin Pieuchot wrote: So I started to play with the routine table and I'm slowly trying to unify the various code paths to add and delete route entries. The diff below is a first step, it splits rtinit() into rt_add() and rt_delete() there should be

Re: [PATCH] ELF: ensure PT_INTERP strings are NULL-terminated

2013-08-28 Thread Kenneth R Westerback
On Wed, Aug 28, 2013 at 02:54:11PM +0200, Maxime Villard wrote: Updated diff, with small tweaks from Andres Perera, * int - size_t, signedness issue, even if it can't be INT_MAX * NULL - NUL Index: exec_elf.c === RCS file:

Re: [PATCH] ELF: ensure PT_INTERP strings are NULL-terminated

2013-08-28 Thread Kenneth R Westerback
On Wed, Aug 28, 2013 at 08:44:26PM +0200, Maxime Villard wrote: On 08/28/13 16:30, Kenneth R Westerback wrote: On Wed, Aug 28, 2013 at 02:54:11PM +0200, Maxime Villard wrote: Updated diff, with small tweaks from Andres Perera, * int - size_t, signedness issue, even if it can't be INT_MAX

Re: [PATCH] ELF: ensure PT_INTERP strings are NULL-terminated

2013-08-28 Thread Kenneth R Westerback
On Wed, Aug 28, 2013 at 09:43:24PM +0200, Maxime Villard wrote: On 08/28/13 20:57, Matthew Dempsky wrote: On Wed, Aug 28, 2013 at 5:54 AM, Maxime Villard m...@m00nbsd.net wrote: + /* Ensure interp is a valid, NUL-terminated string */ + for (n =

Re: useradd with empty -k doesn't chown/chmod new home directory

2013-08-31 Thread Kenneth R Westerback
On Sat, Aug 31, 2013 at 06:23:25AM -0600, Todd C. Miller wrote: Assuming we want to make this a non-fatal error the following should do. - todd Index: usr.sbin/user/user.c === RCS file:

Re: Introduce rt_msg() (was nd6_rtmsg)

2013-09-02 Thread Kenneth R Westerback
On Mon, Sep 02, 2013 at 12:43:51PM +0200, Martin Pieuchot wrote: Diff below is just a small refactoring of two similar code chunks to inform user processes that something changed regarding a route. I'd like to get this in because it removes one use of rt_addrinfo in netinet6. There's no

Re: Iso image integrity verification

2013-09-11 Thread Kenneth R Westerback
On Wed, Sep 11, 2013 at 08:53:50PM +0300, Valentin Zagura wrote: I don't think I'm more paranoid than the average considering that Debian has a way to do this (http://www.debian.org/CD/verify), fedora has a way to do this (https://fedoraproject.org/verify), even Freebsd has a way to do this (

Re: Iso image integrity verification

2013-09-12 Thread Kenneth R Westerback
download the image through tor could have some problems if the exit node is malicious. If you feel that any kind of verification is futile, it's ok, that would not stop us from buying the CDs. On Wed, Sep 11, 2013 at 10:32 PM, Kenneth R Westerback kwesterb...@rogers.com wrote: On Wed, Sep 11

Re: Iso image integrity verification

2013-09-12 Thread Kenneth R Westerback
On Thu, Sep 12, 2013 at 07:52:22PM +0300, Valentin Zagura wrote: There is no entity that owns or can be held responsible for the code, or is capable of providing a solid evidentuary path from commit to your hands. I thought if we buy the CDs we WILL get a solid evidentuary path from

Re: Iso image integrity verification

2013-09-13 Thread Kenneth R Westerback
On Fri, Sep 13, 2013 at 11:13:36AM +0300, Valentin Zagura wrote: Security itself is not the primary issue here. The issue is to easily prove an assessor without reasonable doubt that you are running the right thing. They will not worry about governments trying to break in with MITM signed ssl

Re: enc interface errno

2013-09-27 Thread Kenneth R Westerback
On Fri, Sep 27, 2013 at 06:56:04PM +0200, Alexander Bluhm wrote: On Fri, Sep 27, 2013 at 12:00:40PM -0400, Kenneth R Westerback wrote: I'm not sure what the 'rule' is regarding ENOMEM and ENOBUFS, but ENOMEN seems more appropriate to me. man 2 errno 12 ENOMEM Cannot allocate memory

Re: re(4) diff that needs testing

2013-10-02 Thread Kenneth R Westerback
On Tue, Oct 01, 2013 at 09:32:30PM +0200, Mark Kettenis wrote: Some re(4) variants now use msi. Unfortunately the interrupt handler isn't careful enough, and we might miss an interrupt. The diff below seems to fix that by disabling the interrupts while processing an interrupt. This is what

Re: [PATCH] ELF: ensure PT_INTERP strings are NULL-terminated

2013-10-05 Thread Kenneth R Westerback
On Sat, Oct 05, 2013 at 03:22:36PM -0600, Todd C. Miller wrote: On Wed, 28 Aug 2013 22:34:26 -0400, Kenneth R Westerback wrote: @@ -552,11 +552,16 @@ ELFNAME2(exec,makecmds)(struct proc *p, for (i = 0, pp = ph; i eh-e_phnum; i++, pp++) { if (pp-p_type == PT_INTERP

Re: Fixing an LLVM warning in the i2o code

2013-11-04 Thread Kenneth R Westerback
On Sun, Nov 03, 2013 at 10:51:43PM -0500, Brad Smith wrote: LLVM errors out on the i2o code with the following warning.. ../../../../dev/i2o/iop.c:2399:42: error: comparison of unsigned expression 0 is always false [-Werror,-Wtautological-compare] pt-pt_nbufs 0 ||

Re: Fixing an LLVM warning in the i2o code

2013-11-04 Thread Kenneth R Westerback
On Tue, Nov 05, 2013 at 02:24:22AM +1000, David Gwynne wrote: On 5 Nov 2013, at 12:40 am, Kenneth R Westerback kwesterb...@rogers.com wrote: On Sun, Nov 03, 2013 at 10:51:43PM -0500, Brad Smith wrote: LLVM errors out on the i2o code with the following warning.. ../../../../dev/i2o

Re: Add fcu(4/macppc) to RAMDISK

2013-11-09 Thread Kenneth R Westerback
On Sat, Nov 09, 2013 at 08:36:23PM +0100, Martin Pieuchot wrote: Without this driver, it's impossible to upgrade my PowerMac7,3 without hearing a fan symphony. ok? As long as all the media still fit this is ok krw@. I don't think there are many in macppc. Ken Index: conf/RAMDISK

Re: FDDI/ATM leftovers

2013-11-18 Thread Kenneth R Westerback
On Mon, Nov 18, 2013 at 11:28:56AM +, Alexey E. Suslikov wrote: Martin Pieuchot mpieuchot at nolizard.org writes: - case IFT_FDDI: - case IFT_ATM: case IFT_IEEE1394: any plans for FireWire? :) Nope. :-) Ken

Re: rename local ticks

2013-11-29 Thread Kenneth R Westerback
On Fri, Nov 29, 2013 at 04:50:17PM -0500, Ted Unangst wrote: bad form, i think, to have a local variable shadow a global. I like it. ok krw@ Ken Index: kern_clock.c === RCS file: /cvs/src/sys/kern/kern_clock.c,v

Re: dhclient support for /32 assignments

2013-12-03 Thread Kenneth R Westerback
On Tue, Dec 03, 2013 at 04:15:10PM -0800, Matthew Dempsky wrote: The patch below extends dhclient to mimic this logic from ISC DHCP's linux script: if [ x$new_subnet_mask = x255.255.255.255 ] ; then route add -host $router dev $interface fi route add

Re: dhclient support for /32 assignments

2013-12-04 Thread Kenneth R Westerback
On Wed, Dec 04, 2013 at 10:57:41AM -0800, Matthew Dempsky wrote: On Tue, Dec 03, 2013 at 11:48:05PM -0500, Kenneth Westerback wrote: Rfc 3442 is what I referred to. I don't think RFC 3442 discusses what to do with /32 IP address assignments though? No, that was my point. i.e. don't avoid

Re: dhclient support for /32 assignments

2013-12-05 Thread Kenneth R Westerback
On Wed, Dec 04, 2013 at 12:47:19PM -0800, Matthew Dempsky wrote: On Wed, Dec 04, 2013 at 02:10:21PM -0500, Kenneth R Westerback wrote: No, that was my point. i.e. don't avoid adding the route when given a /32 address just because class static routes are also present. I think there might

Re: 5.4 amd64 - Poor disk performance with Smart Array 6404

2013-12-09 Thread Kenneth R Westerback
On Mon, Dec 09, 2013 at 07:24:19PM -0500, Adam Jensen wrote: I recently (last night) installed OpenBSD-5.4-amd64 on an HP-Proliant ML370-G4 that has a Smart Array 6404 controller card in a 64-bit, 133-MHz PCI-X slot. It has two Ultra320 SCSI channels and 192MB of RAM cache. One SCSI channel is

Re: siop(4) man page correction

2011-02-07 Thread Kenneth R Westerback
On Mon, Feb 07, 2011 at 10:24:15AM +0100, Mattieu Baptiste wrote: Hi all, According to src/sys/dev/ic/siop.c rev 1.6, siop(4) supports U160 SCSI. So it should be: --- siop.4.orig Mon Feb 7 10:12:39 2011 +++ siop.4 Mon Feb 7 10:13:58 2011 @@ -85,11 +85,7 @@ .Tn SCSI ) .It

Re: [PATCH] fix broken support for installing on extended partitions

2011-02-11 Thread Kenneth R Westerback
On Fri, Feb 11, 2011 at 05:11:45PM +0200, ucs...@gmail.com wrote: On Fri, Feb 11, 2011 at 06:28:28AM -0500, Kenneth R Westerback wrote: On Fri, Feb 11, 2011 at 09:47:02AM +0200, ucs...@gmail.com wrote: Despite the touted support, OpenBSD wouldn't be able to boot off an extended partition

Re: fix possible NULL deref in sys/dev/usb/uhub.c

2011-02-18 Thread Kenneth R Westerback
On Fri, Feb 18, 2011 at 12:27:40PM +0100, Mike Belopuhov wrote: On Fri, Feb 18, 2011 at 03:44 +, Jacob Meuser wrote: at line 190, if nports == 0, 'hub' will be NULL at line 334, and 'if (hub-ports)' will be a NULL dereference. found by Amit Kulkarni using clang. makes perfect

Re: allow underruns on mpii controllers

2011-02-21 Thread Kenneth R Westerback
On Mon, Feb 21, 2011 at 11:05:40PM +1000, David Gwynne wrote: we do some scsi ops where we give a device a large buffer and expect it to only fill part of it because we dont know how big that part will be. the underrun handling in mpii always caused this to fail, so devices relying on this

Re: OpenBSD crash on an IBM x3550 M3

2011-03-03 Thread Kenneth R Westerback
On Thu, Mar 03, 2011 at 07:11:52PM +0100, Mike Belopuhov wrote: On Fri, Feb 04, 2011 at 14:53 +, emeric boit wrote: Hello, After doing a clean install of OpenBSD 4.8 (AMD64) on an IBM x3550 M3, I find the system randomly panics after a period of use.

Re: PATCH: Fix boolean value for ACPI logical comparisons

2011-03-19 Thread Kenneth R Westerback
On Fri, Mar 18, 2011 at 04:48:13PM -0600, Jordan Hargrave wrote: This patch changes the values of boolean comparisons from 0:1 to 0:-1 (from ACPI Spec) in order to fix an AML issue on some Asus machines. Please test on other machines as well to verify that hardware sensors/acpi/boot work

Fix dhclient message intervals - i.e. make negotiation faster!

2011-03-25 Thread Kenneth R Westerback
Investigating PR#6543 I concluded we are mishandling the intervals between the DCHPDISCOVER packets and also between the DHCPREQUEST packets. Most obvious is the last chunk. - if (stop_selecting = 0) + if (stop_selecting = cur_time) stop_selecting is a time, not an interval. So this

Re: NFS writes lock up system with -o tcp,-w32768

2011-03-29 Thread Kenneth R Westerback
On Tue, Mar 29, 2011 at 05:36:36PM +0200, Walter Haidinger wrote: Am 29.03.2011 17:24, schrieb Michael: Hi, I already filed a PR for that on 17.12.20110 - kernel/6525. There also were some mails on misc@ about it. But noone really seemed to care. Yes, it's status is still open (=no

Re: Fix for CVE-2011-0401

2011-04-01 Thread Kenneth R Westerback
Excellent! I've waited an entire year for this diff! ok krw@. Ken On Fri, Apr 01, 2011 at 10:47:51PM +, Miod Vallat wrote: Tentative fix, mostly by beck@. Would need some IPv6 tests of course. Index: sys/ufs/ufs/ufs_vnops.c

ata.c dma_alloc()

2011-04-02 Thread Kenneth R Westerback
Yet another driver that probably wouldn't like big mem. ok? Ken Index: dev/ata/ata.c === RCS file: /cvs/src/sys/dev/ata/ata.c,v retrieving revision 1.30 diff -u -p -r1.30 ata.c --- dev/ata/ata.c 23 Jul 2010 07:47:12 -

Re: remove bufqs from vnds

2011-04-02 Thread Kenneth R Westerback
On Sat, Apr 02, 2011 at 01:58:22PM +, Thordur Bjornsson wrote: Hi, So, it doesn't make sense to have a bufq for vnds. The disk that stores the image backing the vnd has it's own bufq ofcourse and what happens is that vnd puts a buf on it's bufq, which is promptly removed when we

Dump stupid dhclient script uses/phases

2011-04-03 Thread Kenneth R Westerback
Resolved, that 1) dhclient(8) forces the interface link up with interface_link_forceup(). Why call the script with PREINIT to call 'ifconfig blah up'? 2) ALIAS declarations in dhclient.conf were/are an experimental feature. Mixing dhclient and 'manual' info is incoherent, dangerous and

ahci big mem friendlification

2011-04-03 Thread Kenneth R Westerback
Another allocation/memory use made big mem friendly. Ken Index: ahci.c === RCS file: /cvs/src/sys/dev/pci/ahci.c,v retrieving revision 1.172 diff -u -p -r1.172 ahci.c --- ahci.c 28 Jan 2011 06:32:31 - 1.172 +++

Re: ahci big mem friendlification

2011-04-03 Thread Kenneth R Westerback
On Sun, Apr 03, 2011 at 09:38:44AM -0400, Kenneth R Westerback wrote: Another allocation/memory use made big mem friendly. Ken Try to avoid allocating memory in interrupt context, as pointed out by dlg@. Ken Index: ahci.c

softraid iopoolification

2011-04-03 Thread Kenneth R Westerback
Works on my crypto volume. People with other volume types would be nice to hear from. Ken Index: softraid.c === RCS file: /cvs/src/sys/dev/softraid.c,v retrieving revision 1.222 diff -u -p -r1.222 softraid.c --- softraid.c 15

Re: no swapping to vnds

2011-04-04 Thread Kenneth R Westerback
On Mon, Apr 04, 2011 at 09:22:41AM +, Thordur Bjornsson wrote: Hi, 1) Swapping to svnds has issues (pagedaemon deadlocks) and has been broken since forever. 2) Swapping to vnds makes no sense, why add another layer when you can just swap to a regular file instead ? so stop

Re: softraid iopoolification

2011-04-04 Thread Kenneth R Westerback
On Sun, Apr 03, 2011 at 07:01:04PM -0400, Kenneth R Westerback wrote: Works on my crypto volume. People with other volume types would be nice to hear from. Ken v2. Use scsi_io_[get|put](), stop trying so hard to avoid calling scsi_done() at SPLBIO as this is nice but not necessary

Re: softraid iopoolification

2011-04-04 Thread Kenneth R Westerback
On Mon, Apr 04, 2011 at 10:47:37AM -0400, Kenneth R Westerback wrote: On Sun, Apr 03, 2011 at 07:01:04PM -0400, Kenneth R Westerback wrote: Works on my crypto volume. People with other volume types would be nice to hear from. Ken v2. Use scsi_io_[get|put](), stop trying so hard

ahd(4) prerequisite for iopoolification

2011-04-05 Thread Kenneth R Westerback
We never allocate 253 scb's, and thus tag collisions should not be possible if they are correctly initialized. This diff just rips out the existing collision code. I haven't yet determined if we need to initialize tags differently. It is a prerequisite for iopoolification and testing on any ahd

Re: mechanic rename M_{TCP|UDP}V4_CSUM_OUT - M_{TCP|UDP}_CSUM_OUT

2011-04-05 Thread Kenneth R Westerback
On Tue, Apr 05, 2011 at 06:19:32PM +0200, Henning Brauer wrote: so i wanna change the world order a bit again. basically, no part of the tree should bother with setting tcp and udp checksums. when they are needed, the stack just sets these flags, and ip_output / ip6_output do the checksum

Re: no really, be quiet mode for ping{,6}

2011-04-06 Thread Kenneth R Westerback
On Wed, Apr 06, 2011 at 03:19:00PM -0400, Ted Unangst wrote: On Wed, Apr 6, 2011 at 7:00 AM, Peter Hessler phess...@openbsd.org wrote: I use silent ping very often (especially in scripts and cronjobs), and it pisses me off that I need to redirect to /dev/null. I'm scratching an itch, here.

Re: fsck_ffs diff needs testing

2011-04-07 Thread Kenneth R Westerback
On Thu, Apr 07, 2011 at 11:08:05AM +0200, Otto Moerbeek wrote: Hi, I got little feedeback on this diff posed in a rather long thread, so I am posting it again. Please test this, it makes fsck_ffs much faster (especially with -p) and less memory hungry in a lot of cases. Note that to

gdt(4) iopoolification - test now or forever hold your peace

2011-04-07 Thread Kenneth R Westerback
As with cac(4). You can test now or can break later. Ken Index: ic/gdt_common.c === RCS file: /cvs/src/sys/dev/ic/gdt_common.c,v retrieving revision 1.55 diff -u -p -r1.55 gdt_common.c --- ic/gdt_common.c 12 Oct 2010

dhclient(8) vs classful static routes

2011-04-07 Thread Kenneth R Westerback
Classful routing is no longer widely used. Our current support for DHCP option 33 (DHO_STATIC_ROUTES) does not treat the provided information as classful routes but as host routes. Is this deliberate or accidental on our part? If accidental I would recommend the diff below, removing the handling

Re: system/6586: rdist (file larger than 2GB) times out but will not die -- Testers needed

2011-04-10 Thread Kenneth R Westerback
No need to copy bugs@, tech@ and misc@. One is enough. I pick tech@. There a few size_t vs ssize_t inconsistencies but this looks very good for a start. I would suggest that as we are changing strtol and atoi calls that we take the opportunity to replace them with strtonum calls. Ken On

Re: system/6586: rdist (file larger than 2GB) times out but will not die -- Testers needed

2011-04-10 Thread Kenneth R Westerback
On Sat, Apr 09, 2011 at 11:20:09AM -0400, Steven R. Gerber wrote: Hi folks. Current rdist will timeout with files 2GB, log as finished, but will not die. The bug (system/6586) was originally noted by IBM (AIX) in 2006: https://www-304.ibm.com/support/docview.wss?uid=isg1IY85396 I have

Re: system/6586: rdist (file larger than 2GB) times out but will not die

2011-04-10 Thread Kenneth R Westerback
On Sat, Apr 09, 2011 at 03:21:40PM -0400, Steven R. Gerber wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 4/9/2011 1:04 PM, Theo de Raadt wrote: When you print and off_t, for portability you should use: %lld, (long long)offt I'm a bit confused by the different

Re: Remove odd code in wskbd.c

2011-04-13 Thread Kenneth R Westerback
On Wed, Apr 13, 2011 at 09:19:12PM +0600, Alexandr Shadchin wrote: Hi! wskbd_holdscreen() is not needed and can be removed. ok? -- Alexandr Shadchin ok krw@ Ken Index: wskbd.c === RCS file:

Re: Reducing number of call update_leds()

2011-04-13 Thread Kenneth R Westerback
On Thu, Apr 14, 2011 at 12:35:18AM +0600, Alexandr Shadchin wrote: Updating state LED only when necessary. ok? -- Alexandr Shadchin Index: wskbd.c === RCS file: /cvs/src/sys/dev/wscons/wskbd.c,v retrieving revision 1.65

disklabel -F|-f should print swap partitions too.

2011-04-16 Thread Kenneth R Westerback
If we are trying to create a faux fstab for a disk, it should include any swap partitions on the disk. Other than general aesthetic appeal, this will help the install script. Anybody know of reasons not to included the swap partitions in -F|-f output? Ken Index: editor.c

Re: disklabel -F|-f should print swap partitions too.

2011-04-16 Thread Kenneth R Westerback
On Sat, Apr 16, 2011 at 05:48:03PM +0100, Jason McIntyre wrote: On Sat, Apr 16, 2011 at 12:11:19PM -0400, Kenneth R Westerback wrote: If we are trying to create a faux fstab for a disk, it should include any swap partitions on the disk. Other than general aesthetic appeal, this will help

Re: disklabel -F|-f should print swap partitions too.

2011-04-17 Thread Kenneth R Westerback
On Sun, Apr 17, 2011 at 07:26:28AM +0100, Jason McIntyre wrote: On Sat, Apr 16, 2011 at 07:29:27PM -0400, Kenneth R Westerback wrote: My suggested man page tweaks are below. Ken Index: share/man/man5/fstab.5

rdist assumes read() can't fail

2011-04-18 Thread Kenneth R Westerback
r1.18 of rdist/docmd.c changed while ((len = read(fd, buf, sizeof(buf))) != (size_t)-1) to while ((len = read(fd, buf, sizeof(buf))) 0) when fixing PR#5009. Which allowed detection of a return value of 0, i.e. end of file. However len is size_t and thus does not grok -1 and

Re: uname(3) return values

2011-04-18 Thread Kenneth R Westerback
On Tue, Apr 19, 2011 at 01:15:11AM +0200, Ingo Schwarze wrote: Hi Matthew and Joachim, Matthew Dempsky wrote on Mon, Apr 18, 2011 at 11:34:50AM -0700: The issue here (if any) is that we over-specify the *successful* return value as precisely 0, rather than generally non-negative. I

Re: automatically set the default console?

2011-04-19 Thread Kenneth R Westerback
On Tue, Apr 19, 2011 at 12:21:57PM +0200, Peter Hessler wrote: When I'm installing over a serial line, I would expect to use that as my console in the future. This diff sets the default console to the one we are currently using, so it's just another [enter]. (The style is based on the xdm

eliminate gdt(4) raw_scsi mode

2011-04-19 Thread Kenneth R Westerback
gdt(4) man page says 'transparent raw SCSI mode' is unsupported. The code just returns errors to any attempts to submit i/o. I'm pretty sure nobody is going to add support so eliminate the framework for it. Shrinks the iopool diff. Any dissenting voices? Ken Index: share/man/man4/gdt.4

Re: fsck_ffs: remove support support for old formats

2011-04-23 Thread Kenneth R Westerback
On Sat, Apr 23, 2011 at 12:52:46PM +0200, Otto Moerbeek wrote: Little feedback on this, If you have good reasons to keep the ability to convert and/or check (very) old ffs on-disk formats, speak up now. -Otto Let the old crap molder in the grave and not disturb us. If you want to

Re: malloc: speed vs randomization

2011-04-28 Thread Kenneth R Westerback
On Thu, Apr 28, 2011 at 11:12:40AM +0200, Otto Moerbeek wrote: On Tue, Apr 26, 2011 at 09:13:47PM +0200, Otto Moerbeek wrote: Second version of diff. This is a conservative one, i.e. it does not change randomization in any way. The diff achieves a speedup by: - Move from long units

Re: macppc: support for Dynamic Frequency Switching

2011-05-04 Thread Kenneth R Westerback
On Wed, May 04, 2011 at 11:58:16AM +0100, Stuart Henderson wrote: On 2011/05/04 16:11, Martin Pieuchot wrote: Looks good! Unfortunately the G4 mini (which has the MPC7447A) doesn't support this. Can you send me your device-tree dump? If it's really a MPC7447A (not a MPC7447)

tunefs(8) don't need no stinkin' opendisk(3). And wants DUIDs!

2011-05-04 Thread Kenneth R Westerback
And by using opendev(3) tunefs can accept disk UID's. Any actual tunefs(8) guru's out there who can explain what this might break? Inspired by oga@'s work on atactl. This is the last use of opendisk(3) in the tree. Any reason to keep it if this goes in? ports? Ken Index: tunefs.c

Re: tunefs(8) don't need no stinkin' opendisk(3). And wants DUIDs!

2011-05-05 Thread Kenneth R Westerback
On Thu, May 05, 2011 at 08:09:16AM -0400, Kenneth R Westerback wrote: On Thu, May 05, 2011 at 11:51:22AM +0100, Owain Ainsworth wrote: On Wed, May 04, 2011 at 11:59:52PM -0400, Kenneth R Westerback wrote: And by using opendev(3) tunefs can accept disk UID's. Any actual tunefs(8

Re: Eliminating unused WDC_CAPABILITY_* flags

2011-05-08 Thread Kenneth R Westerback
On Sat, May 07, 2011 at 09:01:19PM -0700, Matthew Dempsky wrote: I have plans to revamp dev/ic/wdc.c, but in the mean time, I want to make some small cleanups so the final diff is easier to follow. First cleanup: The HWLOCK, ATA_NOSTREAM, and ATAPI_NOSTREAM 'capabilities' don't appear to be

Re: cron: NULL pointer dereference in load_entry()

2011-05-10 Thread Kenneth R Westerback
On Tue, May 10, 2011 at 06:57:29AM +0200, Otto Moerbeek wrote: On Mon, May 09, 2011 at 08:51:01PM -0400, Lawrence Teo wrote: In the load_entry() function in cron's entry.c, calloc() is called but its return value is never checked to see if it is NULL, potentially causing a NULL pointer

dhclient(8) vs Nortel NetID vs DHO_DHCP_MESSAGE_TYPE

2011-05-10 Thread Kenneth R Westerback
PR#6543 reports a failure to obtain a DHCP lease. Further investigation with the submitter has shown that the DHCP server in question (Nortel NetID v4.5.0) is sensitive to the position of the DHO_DHCP_MESSAGE_TYPE option. We currently simply write out the options in numerical order, which results

Re: cron: NULL pointer dereference in load_entry()

2011-05-10 Thread Kenneth R Westerback
On Tue, May 10, 2011 at 10:01:00PM -0400, Lawrence Teo wrote: On Tue, May 10, 2011 at 08:46:04AM -0400, Kenneth R Westerback wrote: On Tue, May 10, 2011 at 06:57:29AM +0200, Otto Moerbeek wrote: On Mon, May 09, 2011 at 08:51:01PM -0400, Lawrence Teo wrote: In the load_entry

Re: macppc: support for Dynamic Frequency Switching

2011-05-15 Thread Kenneth R Westerback
On Sun, May 15, 2011 at 03:56:16PM +0530, Martin Pieuchot wrote: On 04/05/11(Wed) 20:29, Miod Vallat wrote: Speaking of DELAY()... it is implemented using the processor internal counter register. Is this register impacted by frequency changes? If so, shouldn't you update the computed

Re: resizing auto-allocated labels

2011-05-21 Thread Kenneth R Westerback
I like this a lot. Can we use stronum() and avoid the manual operator processing? Ken On Sat, May 21, 2011 at 10:01:01PM +0200, Otto Moerbeek wrote: Hi, it is already possible to resize auto alloctaed labels using the R command in disklabel. But a problem quite a few persons mentioned

Re: resizing auto-allocated labels

2011-05-22 Thread Kenneth R Westerback
On Sun, May 22, 2011 at 07:13:15AM +0200, Otto Moerbeek wrote: On Sat, May 21, 2011 at 09:57:54PM -0400, Kenneth R Westerback wrote: I like this a lot. Can we use stronum() and avoid the manual operator processing? Don't think so. Fractions like 0.5g would break. -Otto Ah

Re: resizing auto-allocated labels

2011-05-22 Thread Kenneth R Westerback
On Sun, May 22, 2011 at 03:35:33PM +0200, Otto Moerbeek wrote: On Sun, May 22, 2011 at 03:02:09PM +0200, Otto Moerbeek wrote: On Sun, May 22, 2011 at 02:59:32PM +0200, Mark Kettenis wrote: Date: Sun, 22 May 2011 13:41:56 +0100 From: Stuart Henderson s...@spacehopper.org

Re: Add interface groups for dhcpd, fix whitespaces

2011-05-27 Thread Kenneth R Westerback
On Fri, May 27, 2011 at 01:22:24PM +0200, Reyk Floeter wrote: On Fri, May 27, 2011 at 11:11:37AM +0200, Michal Mazurek wrote: Add listening on interface groups for dhcpd, from gilles@' smtpd. the dhcpd bit is interesting. Add static to is_if_in_group in smtpd and relayd. i normally

Re: enable msi for ix(4)

2011-05-31 Thread Kenneth R Westerback
On Tue, May 31, 2011 at 10:21:33AM +0200, Peter Hessler wrote: similar to other such diffs, this enables msi for ix(4). OK? Index: dev/pci/if_ix.c === RCS file: /cvs/src/sys/dev/pci/if_ix.c,v retrieving revision 1.51 diff

disklabel -e loses (temporarily) bounds

2011-06-01 Thread Kenneth R Westerback
matthew@ noticed that using 'disklabel -e' seems to lose the starting and ending bounds for the OpenBSD area on the disk. This is a result of getasciilabel() deliberately ignoring label fields that are forcibly set by the OS when the disklabel is read. If you reboot or otherwise force the

ahci msi_map with fallback

2011-06-01 Thread Kenneth R Westerback
Try msi and fallback to old intr mapping. Works on my box where the ahci is on a non-msi bus. ok? Ken Index: ahci.c === RCS file: /cvs/src/sys/dev/pci/ahci.c,v retrieving revision 1.178 diff -u -p -r1.178 ahci.c --- ahci.c

Re: somewhat important amd64 diff

2011-06-09 Thread Kenneth R Westerback
On Thu, Jun 09, 2011 at 12:18:06AM +0200, Mark Kettenis wrote: The current amd64 code allows for a fairly limited number of device interrupts on the primary CPU. The exact number is a bit fuzzy, but is somewhere between 11 and 27. If you go beyond this limit, the interrupts will be sent to a

Re: Fix ISA autoconfusion

2011-06-14 Thread Kenneth R Westerback
On Mon, Jun 13, 2011 at 11:15:44PM -0700, Matthew Dempsky wrote: isa(4) is an indirect bus, which means that drivers that attach to it need to provide an xxxprobe() method instead of an xxxmatch() method. The critical difference is xxxprobe() is given a device softc for the second argument,

Re: dont let sdmmc devices respond to scsi vpd queries

2011-06-15 Thread Kenneth R Westerback
On Wed, Jun 15, 2011 at 01:27:03PM +1000, David Gwynne wrote: ie, check if the VPD bit is set when an inquiry is issued and stop if it is. adds a free check for the cdblen there too. i cant even ping my x60 atm, so i cant test. anyone else want to give it a spin? I have several sdmmc

Re: pf cleanup diff

2011-06-15 Thread Kenneth R Westerback
On Tue, Jun 14, 2011 at 10:23:36PM +0200, Claudio Jeker wrote: On Wed, Jun 08, 2011 at 09:53:24AM +0200, Claudio Jeker wrote: Next step on my quest to unify pf_test and pf_test6. Move the fragment handling and some other protocol specific tests into pf_setup_pdesc(). IPv6 already does this

Re: pf cleanup diff

2011-06-15 Thread Kenneth R Westerback
On Wed, Jun 15, 2011 at 09:50:51PM -0400, Kenneth R Westerback wrote: On Tue, Jun 14, 2011 at 10:23:36PM +0200, Claudio Jeker wrote: On Wed, Jun 08, 2011 at 09:53:24AM +0200, Claudio Jeker wrote: Next step on my quest to unify pf_test and pf_test6. Move the fragment handling and some

Re: pf cleanup diff

2011-06-16 Thread Kenneth R Westerback
On Thu, Jun 16, 2011 at 11:18:30PM +0200, Claudio Jeker wrote: On Wed, Jun 15, 2011 at 11:06:16PM -0400, Kenneth R Westerback wrote: On Wed, Jun 15, 2011 at 09:50:51PM -0400, Kenneth R Westerback wrote: On Tue, Jun 14, 2011 at 10:23:36PM +0200, Claudio Jeker wrote: On Wed, Jun 08, 2011

4096 byte sector devices (a.k.a. disks 3TB)

2011-06-20 Thread Kenneth R Westerback
I committed a fix to fdisk(8) today to un-break the -i and -e options on 4096-byte devices. To make a long story short, it had been working accidentally until I committed a 4.9 change to fdisk(8) to make it pay attention to the errors returned from MBR_read(). However this has raised once more

Re: more useless casts in dev

2011-06-21 Thread Kenneth R Westerback
On Tue, Jun 21, 2011 at 02:27:45PM -0400, Ted Unangst wrote: more casts, not needed. sure. ok krw@. Ken Index: pci/if_bge.c === RCS file: /home/tedu/cvs/src/sys/dev/pci/if_bge.c,v retrieving revision 1.306 diff -u

Re: bus_dmamem_map fix (test+ok)

2011-06-21 Thread Kenneth R Westerback
On Tue, Jun 21, 2011 at 09:00:49PM +0200, Ariane van der Steldt wrote: Hi, Bus_dmamem_map has a bug in its error path, where it frees the wrong memory in the wrong way. Take this code in sparc64 for example: va = uvm_km_valloc(kernel_map, size); ...

Re: Identifying disks by name

2011-06-22 Thread Kenneth R Westerback
On Wed, Jun 22, 2011 at 06:48:14PM +0200, Wouter Coene wrote: Hi all, The patch below builds on the disk UID code to implement disk names. Disk names must match [a-zA-Z0-9_]{1,10} and are stored encoded as 6 bits per character into the disklabel UID field. With this patch, you can use disk

Re: ansi some files in dev

2011-06-22 Thread Kenneth R Westerback
sure. ok krw@ Ken On Wed, Jun 22, 2011 at 01:06:49PM -0400, Ted Unangst wrote: checked with md5, before line folding caused differences. Index: cninit.c === RCS file: /home/tedu/cvs/src/sys/dev/cninit.c,v retrieving

Re: Future of ccd(4) and raid(4)?

2011-06-23 Thread Kenneth R Westerback
On Thu, Jun 23, 2011 at 04:39:19PM -0700, Matthew Dempsky wrote: What should be done about ccd(4) and raid(4)? They both seem superseded in functionality by softraid(4), which also has much more developer interest and active development. Are there any users still using ccd(4) and/or raid(4)

Re: Future of ccd(4) and raid(4)?

2011-06-23 Thread Kenneth R Westerback
On Thu, Jun 23, 2011 at 07:44:52PM -0700, Matthew Dempsky wrote: On Thu, Jun 23, 2011 at 7:29 PM, Kenneth R Westerback kwesterb...@rogers.com wrote: I use neither but know people claim to be using one or the other, but mostly raid(4), a.k.a. raidframe. Then it sounds like the solution

Re: clarify mount_ntfs

2011-06-27 Thread Kenneth R Westerback
On Mon, Jun 27, 2011 at 12:08:15AM -0400, Ted Unangst wrote: Remove some words that are not typically found in OpenBSD mount man pages. Write support is simply not going to happen, so we can summarize that situation much more succinctly. (and enforce readonly mounts in the program.)

Re: clarify mount_ntfs

2011-06-27 Thread Kenneth R Westerback
On Mon, Jun 27, 2011 at 12:06:29PM -0400, Ted Unangst wrote: On Mon, 27 Jun 2011, Kenneth R Westerback wrote: On Mon, Jun 27, 2011 at 12:08:15AM -0400, Ted Unangst wrote: Remove some words that are not typically found in OpenBSD mount man pages. Write support is simply not going

  1   2   3   >