Re: ksh(1): preserve xtrace option

2017-01-16 Thread frantisek holop
Anton Lindqvist, 16 Jan 2017 10:02:
> > Hmm, I see now that my memory is false, ksh93 (available as port) does
> > trace into functions. Still, I'm undecided if we want to change our
> > ksh.
> 
> Any thoughts from others on changing the defaults?

just my 2 cents.
when many years ago i found out that ksh does not trace
into functions i also considered it a bug.

in the tools and languages i use, when a debug mode is
set, one is not expected to reconfirm that setting in
every entered function.  i think the "least surprising
result" would be to trace into functions, and disable
tracing in the particular function where tracing is not
desired...

as i personally want to see all debug output,
i always have a global set -x and local set -x's.
as such i am all for the change.

-f
-- 



gzip keep input files patch

2017-01-07 Thread frantisek holop
hello,

here is a simple patch to add -k (keep) flag to
gzip/compress.  freebsd has it, netbsd has it (although
omitted from the manpages), linux has it.

my use case is automating gzip compression for nginx's
ngx_http_gzip_static_module that can serve
precompressed files from the same directory, but
i also need to keep the input files.

i am aware that
$ gzip -c file > file.gz
does the same, but -k could make certain things easier:

$ find . -name "*.html" -exec gzip -k {} \;

-f
-- 
Index: compress.1
===
RCS file: /cvs/src/usr.bin/compress/compress.1,v
retrieving revision 1.48
diff -u -p -r1.48 compress.1
--- compress.1  17 Mar 2014 14:23:50 -  1.48
+++ compress.1  7 Jan 2017 19:10:58 -
@@ -44,7 +44,7 @@
 .Nd compress and expand data (compress mode)
 .Sh SYNOPSIS
 .Nm compress
-.Op Fl 123456789cdfghlNnOqrtv
+.Op Fl 123456789cdfghklNnOqrtv
 .Op Fl b Ar bits
 .Op Fl o Ar filename
 .Op Fl S Ar suffix
@@ -192,6 +192,8 @@ Use the deflate scheme, which reportedly
 mode).
 .It Fl h
 Print a short help message.
+.It Fl k
+Keep (do not delete) input files during compression or decompression.
 .It Fl l
 List information for the specified compressed files.
 The following information is listed:
Index: gzip.1
===
RCS file: /cvs/src/usr.bin/compress/gzip.1,v
retrieving revision 1.14
diff -u -p -r1.14 gzip.1
--- gzip.1  7 Oct 2014 21:06:30 -   1.14
+++ gzip.1  7 Jan 2017 19:10:58 -
@@ -183,6 +183,8 @@ behave as
 .Xr cat 1 .
 .It Fl h
 Print a short help message.
+.It Fl k
+Keep (do not delete) input files during compression or decompression.
 .It Fl L
 A no-op which exists for compatibility only.
 On GNU gzip, it displays the program's license.
Index: main.c
===
RCS file: /cvs/src/usr.bin/compress/main.c,v
retrieving revision 1.94
diff -u -p -r1.94 main.c
--- main.c  3 Sep 2016 13:26:50 -   1.94
+++ main.c  7 Jan 2017 19:10:58 -
@@ -51,6 +51,7 @@
 #define min(a,b) ((a) < (b)? (a) : (b))
 
 int cat, decomp, pipin, force, verbose, testmode, list, recurse, storename;
+int keep;
 extern char *__progname;
 
 const struct compressor {
@@ -73,7 +74,7 @@ const struct compressor {
"deflate",
".gz",
"\037\213",
-   "123456789ab:cdfhLlNnOo:qrS:tVv",
+   "123456789ab:cdfhkLlNnOo:qrS:tVv",
"cfhLlNno:qrtVv",
"fhqr",
gz_ropen,
@@ -90,7 +91,7 @@ const struct compressor {
"compress",
".Z",
"\037\235",
-   "123456789ab:cdfghlNnOo:qrS:tv",
+   "123456789ab:cdfghklNnOo:qrS:tv",
"cfhlNno:qrtv",
"fghqr",
z_ropen,
@@ -108,7 +109,7 @@ const struct compressor null_method = {
"null",
".nul",
"XX",
-   "123456789ab:cdfghlNnOo:qrS:tv",
+   "123456789ab:cdfghklNnOo:qrS:tv",
"cfhlNno:qrtv",
"fghqr",
null_ropen,
@@ -139,6 +140,7 @@ const struct option longopts[] = {
{ "uncompress", no_argument,0, 'd' },
{ "force",  no_argument,0, 'f' },
{ "help",   no_argument,0, 'h' },
+   { "keep",   no_argument,0, 'k' },
{ "list",   no_argument,0, 'l' },
{ "license",no_argument,0, 'L' },
{ "no-name",no_argument,0, 'n' },
@@ -274,6 +276,9 @@ main(int argc, char *argv[])
strlcpy(suffix, method->suffix, sizeof(suffix));
bits = 6;
break;
+   case 'k':
+   keep++;
+   break;
case 'l':
list++;
testmode = 1;
@@ -456,7 +461,7 @@ main(int argc, char *argv[])
 
switch (error) {
case SUCCESS:
-   if (!cat && !testmode) {
+   if (!cat && !testmode && !keep) {
if (!pipin && unlink(infile) && verbose >= 0)
warn("input: %s", infile);
}
@@ -939,7 +944,7 @@ usage(int status)
 
switch (pmode) {
case MODE_COMP:
-   fprintf(stderr, "usage: %s [-123456789cdf%sh%slNnOqrt%sv] "
+   fprintf(stderr, "usage: %s [-123456789cdf%shk%slNnOqrt%sv] "
"[-b bits] [-o filename] [-S suffix]\n"
"   %*s [file ...]\n", __progname,
!gzip ? "g" : "", gzip ? "L" : "", gzip ? "V" : "",


Re: new feature in pkg_add(1)

2016-06-19 Thread frantisek holop
does this deprecate -z ?

-f
-- 
there's no second chance for a good first impression.



Re: find errors in "make tags"

2016-05-29 Thread frantisek holop
frantisek holop, 29 May 2016 16:24:
> btw. making tags for /usr/src fails for me atm:
> ...
> ===> gnu/usr.bin/cc/cc_int
> make: don't know how to make genrtl.c (prerequisite of: tags)
> Stop in gnu/usr.bin/cc/cc_int
> *** Error 2 in gnu/usr.bin/cc (:48 'tags')
> *** Error 1 in gnu/usr.bin (:48 'tags')
> *** Error 1 in gnu (:48 'tags')
> *** Error 1 in /usr/src (:48 'tags')

this is false alarm, i was missing a make depend.
sorry about this noise.

-f
-- 
the smallest handcuff in the world is a wedding ring.



find errors in "make tags"

2016-05-29 Thread frantisek holop
$ cd /usr/src/sys
$ make tags
cd /usr/src/sys/kern; make tags
...
find: /usr/src/sys/arch/armish/../../lib/libkern/arch/armish: No such file or 
directory
...
find: /usr/src/sys/arch/armv7/../../lib/libkern/arch/armv7: No such file or 
directory
...
find: /usr/src/sys/arch/landisk/../../lib/libkern/arch/landisk: No such file or 
directory
...
find: /usr/src/sys/arch/loongson/../../lib/libkern/arch/loongson: No such file 
or directory
...
find: /usr/src/sys/arch/luna88k/../../lib/libkern/arch/luna88k: No such file or 
directory
...
find: /usr/src/sys/arch/macppc/../../lib/libkern/arch/macppc: No such file or 
directory
...
find: /usr/src/sys/arch/octeon/../../lib/libkern/arch/octeon: No such file or 
directory
...
find: /usr/src/sys/arch/sgi/../../lib/libkern/arch/sgi: No such file or 
directory
...
find: /usr/src/sys/arch/socppc/../../lib/libkern/arch/socppc: No such file or 
directory
...
find: /usr/src/sys/arch/zaurus/../../lib/libkern/arch/zaurus: No such file or 
directory

if these archs are using libkern/arch/arm instead, and
if there is a chance that some .h files will show up
there in the future, maybe changing _mach to _arch is
preferable.  this patch does that.  removed some
needless quotes while here.

btw. making tags for /usr/src fails for me atm:
...
===> gnu/usr.bin/cc/cc_int
make: don't know how to make genrtl.c (prerequisite of: tags)
Stop in gnu/usr.bin/cc/cc_int
*** Error 2 in gnu/usr.bin/cc (:48 'tags')
*** Error 1 in gnu/usr.bin (:48 'tags')
*** Error 1 in gnu (:48 'tags')
*** Error 1 in /usr/src (:48 'tags')

-f



Index: sys/arch/armish/Makefile
===
RCS file: /cvs/src/sys/arch/armish/Makefile,v
retrieving revision 1.6
diff -u -p -r1.6 Makefile
--- sys/arch/armish/Makefile8 Dec 2013 14:46:39 -   1.6
+++ sys/arch/armish/Makefile29 May 2016 13:53:54 -
@@ -25,7 +25,7 @@ tags::
eval "_mach=\"`make -V _mach -f $${TDIR}/Makefile`\"" && \
eval "_machdir=\$S/arch/$${_mach}" && \
eval "_archdir=\$S/arch/$${_arch}" && \
-   eval "HFILES=\"`find $S \( -path $S/'arch' -o -path $S/stand -o -path 
$S/lib/libsa -o -path $S'/lib/libkern/arch' \) -prune -o -name '*.h'; find 
$${_machdir} $${_archdir} $S/lib/libkern/arch/$${_mach} \( -name boot -o -name 
stand \) -prune -o -name '*.h'`\"" && \
+   eval "HFILES=\"`find $S \( -path $S/arch -o -path $S/stand -o -path 
$S/lib/libsa -o -path $S/lib/libkern/arch \) -prune -o -name '*.h'; find 
$${_machdir} $${_archdir} $S/lib/libkern/arch/$${_arch} \( -name boot -o -name 
stand \) -prune -o -name '*.h'`\"" && \
eval "SFILES=\"`make -V SFILES -f $${TDIR}/Makefile`\"" && \
eval "CFILES=\"`make -V CFILES -f $${TDIR}/Makefile`\"" && \
eval "AFILES=\"`make -V AFILES -f $${TDIR}/Makefile`\"" && \
Index: sys/arch/armv7/Makefile
===
RCS file: /cvs/src/sys/arch/armv7/Makefile,v
retrieving revision 1.3
diff -u -p -r1.3 Makefile
--- sys/arch/armv7/Makefile 23 May 2016 02:19:46 -  1.3
+++ sys/arch/armv7/Makefile 29 May 2016 13:53:54 -
@@ -25,7 +25,7 @@ tags::
eval "_mach=\"`make -V _mach -f $${TDIR}/Makefile`\"" && \
eval "_machdir=\$S/arch/$${_mach}" && \
eval "_archdir=\$S/arch/$${_arch}" && \
-   eval "HFILES=\"`find $S \( -path $S/'arch' -o -path $S/stand -o -path 
$S/lib/libsa -o -path $S'/lib/libkern/arch' \) -prune -o -name '*.h'; find 
$${_machdir} $${_archdir} $S/lib/libkern/arch/$${_mach} \( -name boot -o -name 
stand \) -prune -o -name '*.h'`\"" && \
+   eval "HFILES=\"`find $S \( -path $S/arch -o -path $S/stand -o -path 
$S/lib/libsa -o -path $S/lib/libkern/arch \) -prune -o -name '*.h'; find 
$${_machdir} $${_archdir} $S/lib/libkern/arch/$${_arch} \( -name boot -o -name 
stand \) -prune -o -name '*.h'`\"" && \
eval "SFILES=\"`make -V SFILES -f $${TDIR}/Makefile`\"" && \
eval "CFILES=\"`make -V CFILES -f $${TDIR}/Makefile`\"" && \
eval "AFILES=\"`make -V AFILES -f $${TDIR}/Makefile`\"" && \
Index: sys/arch/landisk/Makefile
===
RCS file: /cvs/src/sys/arch/landisk/Makefile,v
retrieving revision 1.7
diff -u -p -r1.7 Makefile
--- sys/arch/landisk/Makefile   8 Dec 2013 14:46:39 -   1.7
+++ sys/arch/landisk/Makefile   29 May 2016 13:53:55 -
@@ -25,7 +25,7 @@ tags::
eval "_mach=\"`make -V _mach -f $${TDIR}/Makefile`\"" && \
eval "_machdir=\$S/arch/$${_mach}" && \
eval "_archdir=\$S/arch/$${_arch}" && \
-   eval "HFILES=\"`find $S \( -path $S/'arch' -o -path $S/stand -o -path 
$S/lib/libsa -o -path $S'/lib/libkern/arch' \) -prune -o -name '*.h'; find 
$${_machdir} $${_archdir} $S/lib/libkern/arch/$${_mach} \( -name boot -o -name 
stand \) -prune -o -name '*.h'`\"" && \
+   eval "HFILES=\"`find $S \( -path $S/arch -o -path $S/stand -o -path 
$S/lib/libsa -o -path $S/lib/libkern/arch \) 

Re: inteldrm diff that requires testing

2016-04-28 Thread frantisek holop
Mark Kettenis, 15 Apr 2016 17:01:
> The diff below makes the HDMI output on Intel Bay Trail machines work.
> Very useful for machines like the Lenovo Ideacentre Stick 300.  But
> this needs to be tested on other hardware as well.  Especially on
> machines with external displays.

i confirm this makes hdmi work on my acer travelmate.
thanks a lot  \o/

$ xrandr
Screen 0: minimum 8 x 8, current 1366 x 768, maximum 32767 x 32767
eDP1 connected 1366x768+0+0 (normal left inverted right x axis y axis) 256mm x 
144mm
   1366x768  60.06*+
   1024x768  60.00
   800x600   60.3256.25
   640x480   59.94
DP1 disconnected (normal left inverted right x axis y axis)
HDMI1 connected (normal left inverted right x axis y axis)
   1920x1080 60.00 +  50.0059.94
   1920x1080i60.0050.0059.94
   1680x1050 59.88
   1400x1050 59.95
   1600x900  59.98
   1280x1024 60.02
   1440x900  59.90
   1280x800  59.91
   1152x864  59.97
   1280x720  60.0050.0059.94
   1024x768  60.00
   800x600   60.32
   720x576   50.00
   720x480   60.0059.94
   640x480   60.0059.94
HDMI2 disconnected (normal left inverted right x axis y axis)
VGA1 disconnected (normal left inverted right x axis y axis)
VIRTUAL1 disconnected (normal left inverted right x axis y axis)


OpenBSD 5.9-current (GENERIC.MP) #1997: Sun Apr 24 17:44:37 MDT 2016
dera...@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP
RTC BIOS diagnostic error 80
real mem = 4158390272 (3965MB)
avail mem = 4027977728 (3841MB)
mpath0 at root
scsibus0 at mpath0: 256 targets
mainbus0 at root
bios0 at mainbus0: SMBIOS rev. 2.7 @ 0xe6eb0 (22 entries)
bios0: vendor Insyde Corp. version "V1.40" date 10/28/2015
bios0: Acer TravelMate B115-M
acpi0 at bios0: rev 2
acpi0: sleep states S0 S3 S4 S5
acpi0: tables DSDT FACP UEFI UEFI SSDT HPET LPIT APIC MCFG SSDT SSDT SSDT SSDT 
SSDT SSDT CSRT SSDT FPDT
acpi0: wakeup devices XHC1(S3) PXSX(S4) RP01(S4) PXSX(S4) RP02(S4) PXSX(S4) 
RP03(S4) PXSX(S4) RP04(S4) EHC1(S3)
acpitimer0 at acpi0: 3579545 Hz, 24 bits
acpihpet0 at acpi0: 14318179 Hz
acpimadt0 at acpi0 addr 0xfee0: PC-AT compat
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: Intel(R) Pentium(R) CPU N3540 @ 2.16GHz, 2167.07 MHz
cpu0: 
FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,SSE4.1,SSE4.2,MOVBE,POPCNT,DEADLINE,RDRAND,NXE,LONG,LAHF,3DNOWP,PERF,ITSC,SMEP,ERMS,SENSOR,ARAT
cpu0: 1MB 64b/line 16-way L2 cache
cpu0: smt 0, core 0, package 0
mtrr: Pentium Pro MTRR support, 8 var ranges, 88 fixed ranges
cpu0: apic clock running at 83MHz
cpu0: mwait min=64, max=64, C-substates=0.2.0.0.0.0.3.3, IBE
cpu1 at mainbus0: apid 2 (application processor)
cpu1: Intel(R) Pentium(R) CPU N3540 @ 2.16GHz, 2166.67 MHz
cpu1: 
FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,SSE4.1,SSE4.2,MOVBE,POPCNT,DEADLINE,RDRAND,NXE,LONG,LAHF,3DNOWP,PERF,ITSC,SMEP,ERMS,SENSOR,ARAT
cpu1: 1MB 64b/line 16-way L2 cache
cpu1: smt 0, core 1, package 0
cpu2 at mainbus0: apid 4 (application processor)
cpu2: Intel(R) Pentium(R) CPU N3540 @ 2.16GHz, 2166.67 MHz
cpu2: 
FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,SSE4.1,SSE4.2,MOVBE,POPCNT,DEADLINE,RDRAND,NXE,LONG,LAHF,3DNOWP,PERF,ITSC,SMEP,ERMS,SENSOR,ARAT
cpu2: 1MB 64b/line 16-way L2 cache
cpu2: smt 0, core 2, package 0
cpu3 at mainbus0: apid 6 (application processor)
cpu3: Intel(R) Pentium(R) CPU N3540 @ 2.16GHz, 2166.67 MHz
cpu3: 
FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,SSE4.1,SSE4.2,MOVBE,POPCNT,DEADLINE,RDRAND,NXE,LONG,LAHF,3DNOWP,PERF,ITSC,SMEP,ERMS,SENSOR,ARAT
cpu3: 1MB 64b/line 16-way L2 cache
cpu3: smt 0, core 3, package 0
ioapic0 at mainbus0: apid 2 pa 0xfec0, version 20, 87 pins
ioapic0: misconfigured as apic 1, remapped to apid 2
acpimcfg0 at acpi0 addr 0xe000, bus 0-63
acpiprt0 at acpi0: bus 0 (PCI0)
acpiprt1 at acpi0: bus 1 (RP01)
acpiprt2 at acpi0: bus 2 (RP02)
acpiprt3 at acpi0: bus 3 (RP03)
acpiprt4 at acpi0: bus -1 (RP04)
acpiec0 at acpi0
acpicpu0 at acpi0: C3(10@1500 mwait.1@0x52), C2(10@500 mwait.1@0x51), C1(1000@1 
mwait.1), PSS
acpicpu1 at acpi0: C3(10@1500 mwait.1@0x52), C2(10@500 mwait.1@0x51), C1(1000@1 
mwait.1), PSS
acpicpu2 at acpi0: C3(10@1500 mwait.1@0x52), C2(10@500 mwait.1@0x51), C1(1000@1 
mwait.1), PSS
acpicpu3 at acpi0: C3(10@1500 mwait.1@0x52), C2(10@500 mwait.1@0x51), C1(1000@1 
mwait.1), PSS
acpipwrres0 at acpi0: PC05, resource for RP01
acpipwrres1 at acpi0: USBC, resource for OTG1, EHC1

Re: Microsoft Now OpenBSD Foundation Gold Contributor

2015-07-11 Thread frantisek holop
Theo de Raadt, 11 Jul 2015 11:43:
  it flatters me somewhat that you read so much into
  my simple astonishment about a news item that does
  in most geek circles provoke the response no way,
  hell froze over.
 
 I quote from your original mail:
 
 this is very impressive news, although for me for all
 the wrong reasons.
 
 Have all the other sponsors contributed for only the right reasons
 over the 20 years?


i always wanted to do a bsd based soap.

TDR: You did not show simple astonishment -- you judged a sponsor.

FH: can't you just accept the fact that i was _happy_
for the foundation?  that despite feeling betrayed
by the fact that my favourite OS accepted stolen money
from a convicted monopolist...

TDR: Enough Leech!  You have an agenda!

sorry, couldn't resist.


 This is our house, and you don't get to insult guests who bring a
 generous green salad to the party.  That is how you become uninvited.

said Mr Goebels to Mrs Goebels after Hitler left the
dinner party.

sorry, couldn't resist again.

gasp, so now a bsd developer tells me i cannot judge
(not that i did) microsoft on an open mailing list,
after said microsoft just donated a bucket of money
to said bsd developer's project?  you can't make this
up, life immitates art.

jesus, you really sound like an american now.
what's next, you gonna sue me?
get a grip man, you are monty python heritage!


in a private email of yours you said you know zero
about microsoft, as you did not have to use it ever.
lucky you!

i wish i could have had that luxury of ignoring them
the same way i could now.  because i know a bit about
microsoft and some of their products as i have been
following them for the last 20 years.

so excuse me when a piece of news like this hits
i become alert, just like 90% of the other non-freaks
out there.  i am sure KRW felt way more surreal writing
that press release than any of us reading it.

why single me out when 90% of the mailing list was
thinking exactly. the. same.  so who has an agenda now?

-f
-- 
down with TLAs! (three letter acronyms)



Re: Microsoft Now OpenBSD Foundation Gold Contributor

2015-07-11 Thread frantisek holop
Theo de Raadt, 09 Jul 2015 21:08:
 As a group (with me and others as the proxy) we do ask for companies
 to help fund us from time to time, and this benefits everyone as a
 result of the common advancements.  As for output, there is no
 discrimination as to their cause, because that is not our
 oversight/job.  The general guidelines for access to software is CLEAR
 in the licence.
 
 Yet you clearly state that we should have some restrictive agenda, Mr.
 Do-Nothing-Except-State-Position.

i wrote no such thing in my email.  not. even. close.

it flatters me somewhat that you read so much into
my simple astonishment about a news item that does
in most geek circles provoke the response no way,
hell froze over.

as a leech, i am of course more than happy when
the project receives funding, no matter the source.

this whole tirade (including your private mails,
that leech etiquette forbids me to quote on an
open mailing list) comes off mildly amusing considering
you yourself foulmouthed a huge donour in the past
(hint hint us army money) and in turn they took their
ball and went home.  now that was damaging.
my email?  oh, please.  get a grip man.


 In essence, you are a loudmouth and a leech.

i am sorry that since i started using openbsd, i sent
its way only around 600 euros for releases, t-shirts,
hats, and mugs; not much perhaps, but i find that
windows users generally never reach this amount,
not by choice anyway.  i am also sorry that i couldn't
send more and better patches, or maintain more ports
than i do.  my contribution overall might not be much
(for whatever value of much), but a pure leech i am
definitely not, no matter how much you try to paint
me as one.  of course, by your logic all openbsd
users are leeches by definition.

maybe a non-leech community member is one that pays
your whole salary or what?


you can't have both: inviting people to contribute
no matter how litle to the project, and then turn
around and call them leeches.  that is not how a
community works, and sadly you could not learn that
even in 20+ years.

and the other bit, the DO MORE FOR ME one is getting
really really old and boring.  i never ever asked for
a feature for myself.  simple smooth operation of the
OS on all my gear is my ultimate goal, a goal every
single member of this community shares.  if you consider
bug reports requests to do work for others, maybe
you should be running a closed commercial project.

-f
-- 
raising your voice does not reinforce your argument.



Re: Microsoft Now OpenBSD Foundation Gold Contributor

2015-07-09 Thread frantisek holop
Kenneth R Westerback, 08 Jul 2015 10:13:
 The OpenBSD Foundation is happy to announce that Microsoft has made
 a significant financial donation to the Foundation. This donation
 is in recognition of the role of the Foundation in supporting the
 OpenSSH project. This donation makes Microsoft the first Gold level
 contributor in the OpenBSD Foundation's 2015 fundraising campaign.

this is very impressive news, although for me for all
the wrong reasons.

sad world when even ms realises openssh's importance,
(even while not supporting it out of box natively)
while the other big open source players are just
feeding off of it.  speechless.

-f
-- 
the current death rate?  one per person, of course.



Re: umass quirk for ignoring residue?

2015-07-03 Thread frantisek holop
Martin Pieuchot, 22 Jun 2015 15:17:
  but this did not seem to help.

while the quirk was committed, my enclosure is still
not working.  here is the output with SCSIDEBUG:

umass0 at uhub0 port 1 configuration 1 interface 0 Super Top USB 2.0  IDE 
DEVICE rev 2.00/2.01 addr 6
umass0: using SCSI over Bulk-Only
scsibus4 at umass0: 2 targets, initiator 0
scsi_inqmatch: 2/0/0 , , 
sd1 at scsibus4 targ 1 lun 0: ST916082, 1A, 0 0 SCSI0 0/direct fixed
sd1(umass0:1:0): Check Condition (error 0x70) on opcode 0x1a
SENSE KEY: Illegal Request
 ASC/ASCQ: Illegal Field in CDB
sd1: 152627MB, 512 bytes/sector, 312581808 sectors
sd1(umass0:1:0): Check Condition (error 0x70) on opcode 0x1a
SENSE KEY: Illegal Request
 ASC/ASCQ: Illegal Field in CDB
sd1(umass0:1:0): Check Condition (error 0x70) on opcode 0x5a
SENSE KEY: Illegal Request
 ASC/ASCQ: Illegal Field in CDB

-f
-- 
senility means never having to drink just to forget.



fix build with SCSIDEBUG

2015-07-01 Thread frantisek holop
i needed something like this to build a kernel with -DSCSIDEBUG

-f
-- 
the next sentence is true.  the last sentence was false.
Index: uha.c
===
RCS file: /cvs/src/sys/dev/ic/uha.c,v
retrieving revision 1.24
diff -u -p -r1.24 uha.c
--- uha.c   14 Sep 2014 14:17:25 -  1.24
+++ uha.c   1 Jul 2015 21:09:13 -
@@ -358,7 +358,7 @@ uha_scsi_cmd(xs)
 * Set up the scatter gather block
 */
SC_DEBUG(sc_link, SDEV_DB4,
-   (%d @0x%x:- , xs-datalen, xs-data));
+   (%d @0x%x:- , xs-datalen, (u_int32_t)xs-data));
datalen = xs-datalen;
thiskv = (int) xs-data;
thisphys = KVTOPHYS(thiskv);
@@ -369,7 +369,7 @@ uha_scsi_cmd(xs)
/* put in the base address */
sg-seg_addr = thisphys;
 
-   SC_DEBUGN(sc_link, SDEV_DB4, (0x%x, thisphys));
+   SC_DEBUGN(sc_link, SDEV_DB4, (0x%x, 
(u_int32_t)thisphys));
 
/* do it at least once */
nextphys = thisphys;


Re: fix build with SCSIDEBUG

2015-07-01 Thread frantisek holop
spoke to soon, other anciet drivers need something like
that.

-f
-- 
experience is nothing but a lot of mistakes.
Index: dev/eisa/aha1742.c
===
RCS file: /cvs/src/sys/dev/eisa/aha1742.c,v
retrieving revision 1.44
diff -u -p -r1.44 aha1742.c
--- dev/eisa/aha1742.c  14 Sep 2014 14:17:24 -  1.44
+++ dev/eisa/aha1742.c  1 Jul 2015 21:29:52 -
@@ -957,7 +957,7 @@ ahb_scsi_cmd(xs)
 * Set up the scatter gather block
 */
SC_DEBUG(sc_link, SDEV_DB4,
-   (%d @0x%x:- , xs-datalen, xs-data));
+   (%d @0x%x:- , xs-datalen, (u_int32_t)xs-data));
datalen = xs-datalen;
thiskv = (long) xs-data;
thisphys = KVTOPHYS(thiskv);
@@ -968,7 +968,7 @@ ahb_scsi_cmd(xs)
/* put in the base address */
sg-seg_addr = thisphys;
 
-   SC_DEBUGN(sc_link, SDEV_DB4, (0x%x, thisphys));
+   SC_DEBUGN(sc_link, SDEV_DB4, (0x%x, 
(u_int32_t)thisphys));
 
/* do it at least once */
nextphys = thisphys;
Index: dev/ic/uha.c
===
RCS file: /cvs/src/sys/dev/ic/uha.c,v
retrieving revision 1.24
diff -u -p -r1.24 uha.c
--- dev/ic/uha.c14 Sep 2014 14:17:25 -  1.24
+++ dev/ic/uha.c1 Jul 2015 21:29:52 -
@@ -358,7 +358,7 @@ uha_scsi_cmd(xs)
 * Set up the scatter gather block
 */
SC_DEBUG(sc_link, SDEV_DB4,
-   (%d @0x%x:- , xs-datalen, xs-data));
+   (%d @0x%x:- , xs-datalen, (u_int32_t)xs-data));
datalen = xs-datalen;
thiskv = (int) xs-data;
thisphys = KVTOPHYS(thiskv);
@@ -369,7 +369,7 @@ uha_scsi_cmd(xs)
/* put in the base address */
sg-seg_addr = thisphys;
 
-   SC_DEBUGN(sc_link, SDEV_DB4, (0x%x, thisphys));
+   SC_DEBUGN(sc_link, SDEV_DB4, (0x%x, 
(u_int32_t)thisphys));
 
/* do it at least once */
nextphys = thisphys;
Index: dev/isa/wds.c
===
RCS file: /cvs/src/sys/dev/isa/wds.c,v
retrieving revision 1.42
diff -u -p -r1.42 wds.c
--- dev/isa/wds.c   14 Sep 2014 14:17:25 -  1.42
+++ dev/isa/wds.c   1 Jul 2015 21:29:52 -
@@ -931,7 +931,7 @@ wds_scsi_cmd(struct scsi_xfer *xs)
 * Set up the scatter-gather block.
 */
SC_DEBUG(sc_link, SDEV_DB4,
-   (%d @0x%x:- , xs-datalen, xs-data));
+   (%d @0x%x:- , xs-datalen, (u_int32_t)xs-data));
 
datalen = xs-datalen;
thiskv = (int)xs-data;
@@ -943,7 +943,7 @@ wds_scsi_cmd(struct scsi_xfer *xs)
/* put in the base address */
ltophys(thisphys, sg-seg_addr);
 
-   SC_DEBUGN(sc_link, SDEV_DB4, (0x%x, thisphys));
+   SC_DEBUGN(sc_link, SDEV_DB4, (0x%x, 
(u_int32_t)thisphys));
 
/* do it at least once */
nextphys = thisphys;


Re: fix build with SCSIDEBUG

2015-07-01 Thread frantisek holop
Miod Vallat, 01 Jul 2015 21:35:
  spoke to soon, other anciet drivers need something like
  that.
 
 Physical address should be printed with %p rather than 0x%x.

explicit cast ok?

-f
-- 
why did kamikaze pilots wear helmets anyway?
Index: dev/eisa/aha1742.c
===
RCS file: /cvs/src/sys/dev/eisa/aha1742.c,v
retrieving revision 1.44
diff -u -p -r1.44 aha1742.c
--- dev/eisa/aha1742.c  14 Sep 2014 14:17:24 -  1.44
+++ dev/eisa/aha1742.c  1 Jul 2015 22:21:35 -
@@ -957,7 +957,7 @@ ahb_scsi_cmd(xs)
 * Set up the scatter gather block
 */
SC_DEBUG(sc_link, SDEV_DB4,
-   (%d @0x%x:- , xs-datalen, xs-data));
+   (%d @%p:- , xs-datalen, (void *)xs-data));
datalen = xs-datalen;
thiskv = (long) xs-data;
thisphys = KVTOPHYS(thiskv);
@@ -968,7 +968,7 @@ ahb_scsi_cmd(xs)
/* put in the base address */
sg-seg_addr = thisphys;
 
-   SC_DEBUGN(sc_link, SDEV_DB4, (0x%x, thisphys));
+   SC_DEBUGN(sc_link, SDEV_DB4, (%p, (void *)thisphys));
 
/* do it at least once */
nextphys = thisphys;
Index: dev/ic/uha.c
===
RCS file: /cvs/src/sys/dev/ic/uha.c,v
retrieving revision 1.24
diff -u -p -r1.24 uha.c
--- dev/ic/uha.c14 Sep 2014 14:17:25 -  1.24
+++ dev/ic/uha.c1 Jul 2015 22:21:35 -
@@ -358,7 +358,7 @@ uha_scsi_cmd(xs)
 * Set up the scatter gather block
 */
SC_DEBUG(sc_link, SDEV_DB4,
-   (%d @0x%x:- , xs-datalen, xs-data));
+   (%d @%p:- , xs-datalen, (void *)xs-data));
datalen = xs-datalen;
thiskv = (int) xs-data;
thisphys = KVTOPHYS(thiskv);
@@ -369,7 +369,7 @@ uha_scsi_cmd(xs)
/* put in the base address */
sg-seg_addr = thisphys;
 
-   SC_DEBUGN(sc_link, SDEV_DB4, (0x%x, thisphys));
+   SC_DEBUGN(sc_link, SDEV_DB4, (%p, (void *)thisphys));
 
/* do it at least once */
nextphys = thisphys;
Index: dev/isa/wds.c
===
RCS file: /cvs/src/sys/dev/isa/wds.c,v
retrieving revision 1.42
diff -u -p -r1.42 wds.c
--- dev/isa/wds.c   14 Sep 2014 14:17:25 -  1.42
+++ dev/isa/wds.c   1 Jul 2015 22:21:35 -
@@ -931,7 +931,7 @@ wds_scsi_cmd(struct scsi_xfer *xs)
 * Set up the scatter-gather block.
 */
SC_DEBUG(sc_link, SDEV_DB4,
-   (%d @0x%x:- , xs-datalen, xs-data));
+   (%d @%p:- , xs-datalen, (void *)xs-data));
 
datalen = xs-datalen;
thiskv = (int)xs-data;
@@ -943,7 +943,7 @@ wds_scsi_cmd(struct scsi_xfer *xs)
/* put in the base address */
ltophys(thisphys, sg-seg_addr);
 
-   SC_DEBUGN(sc_link, SDEV_DB4, (0x%x, thisphys));
+   SC_DEBUGN(sc_link, SDEV_DB4, (%p, (void *)thisphys));
 
/* do it at least once */
nextphys = thisphys;


build with DRMDEBUG

2015-05-30 Thread frantisek holop
this might have been a typo and i can build a kernel
with DRMDEBUG now (failed in radeon_benchmark.c).

-f
-- 
i got real close to seeing elvis but my shovel broke.
Index: drmP.h
===
RCS file: /cvs/src/sys/dev/pci/drm/drmP.h,v
retrieving revision 1.195
diff -u -p -r1.195 drmP.h
--- drmP.h  18 Apr 2015 14:47:34 -  1.195
+++ drmP.h  30 May 2015 17:36:29 -
@@ -188,7 +188,7 @@ drm_can_sleep(void)
curproc-p_pid, __func__ , ## arg)
 
 
-#ifdef DRM_DEBUG
+#ifdef DRMDEBUG
 #define DRM_INFO(fmt, arg...)  printf(drm:  fmt, ## arg)
 #else
 #define DRM_INFO(fmt, arg...) do { } while(/* CONSTCOND */ 0)



Re: Do you need/prefer the non-DUID option in the installer?

2015-04-13 Thread frantisek holop
Joel Sing, 12 Apr 2015 03:14:
 On Wednesday 01 April 2015, frantisek holop wrote:
  Theo de Raadt, 30 Mar 2015 18:09:
   IIRC 'bioctl -d' cannot deal with DUID's.
   not a showstopper, just sayin'
  
   Sounds like you might use this.  Want to trial a diff that adds
   support?  If it is wrong, don't worry, someone will hate your bad
   diff, and do it right.  (That is pretty much the history of DUID
   support in the tools)
 
  yes, i'd like to use it :)  i have numerous softraid
  encrypted usb dongles that i'd like to mount/unmount
  using DUID's.
 
  i started looking into this when i first reported it:
  http://marc.info/?l=openbsd-miscm=138198909623938w=2
  but it was not the one liner i hoped for :)
  i'll try to revisit.
 
  -f
 
 FWIW this is now fixed in r1.351 of src/sys/dev/softraid.c.

lovely, thank you very much.

-f
-- 
first came reality.  then there was wolfenstein 3d...



Re: Do you need/prefer the non-DUID option in the installer?

2015-03-31 Thread frantisek holop
Theo de Raadt, 30 Mar 2015 18:09:
 IIRC 'bioctl -d' cannot deal with DUID's.
 not a showstopper, just sayin'
 
 Sounds like you might use this.  Want to trial a diff that adds
 support?  If it is wrong, don't worry, someone will hate your bad
 diff, and do it right.  (That is pretty much the history of DUID
 support in the tools)

yes, i'd like to use it :)  i have numerous softraid
encrypted usb dongles that i'd like to mount/unmount
using DUID's.

i started looking into this when i first reported it:
http://marc.info/?l=openbsd-miscm=138198909623938w=2
but it was not the one liner i hoped for :)
i'll try to revisit.

-f
-- 
light at end of tunnel will be out until further notice.



Re: Do you need/prefer the non-DUID option in the installer?

2015-03-30 Thread frantisek holop
Theo de Raadt, 15 Mar 2015 12:15:
  Yes I do.  when I install machines that I dump/restore clone, I do
  not use DUID's. it's very nice to make a system without DUID's in
  that case.
 
 I'm sorry, but I don't understand the usage case here which blocks
 DUIDS, so let's see a better explanation or demonstration.
 
 When you have DUIDs in /etc/fstab, you can still use the disk partitions
 using the raw disk names.  The partitions are obvious.  Figuring out which
 disk it is, is really easy, lots of options to provide the translation.
 
 And as far as I know, all the tools have been adapted to accept DUID.

IIRC 'bioctl -d' cannot deal with DUID's.
not a showstopper, just sayin'

-f
-- 
doubt is the beginning of wisdom



qsort.3 big O notation

2015-03-03 Thread frantisek holop

i was looking at the qsort(3) man page,
and saw O N lg N, etc.

first i thought, maybe there should be some fancy utf8
math parentheses around, but looking at the source, no,
it's plain ascii.

a quick search in other man pages reveals an arguably
more readable style:

./share/man/man3/queue.3:overhead at the expense of O(n) removal for arbitrary 
elements.
./share/man/man3/tree.3:and n inserts on an initially empty tree as O((m + n)lg 
n).
./share/man/man3/tree.3:The amortized cost for a sequence of m accesses to a 
splay tree is O(lg n).
./share/man/man3/tree.3:Every operation on a red-black tree is bounded as O(lg 
n).
./share/man/man5/pf.conf.5:If there are 50 rules, all of them are evaluated 
sequentially in O(n).
./share/man/man5/pf.conf.5:searches in O(log2 n).


i leave the battle about lg vs log to others,
but i prefer 'log' as there is a man page for that
and there is none for 'lg'...

-f
-- 
if it wasn't for time everything would happen at once.
Index: ./lib/libc/stdlib/qsort.3
===
RCS file: /cvs/src/lib/libc/stdlib/qsort.3,v
retrieving revision 1.18
diff -u -p -r1.18 qsort.3
--- ./lib/libc/stdlib/qsort.3   29 Jan 2015 01:46:31 -  1.18
+++ ./lib/libc/stdlib/qsort.3   3 Mar 2015 15:56:42 -
@@ -109,9 +109,9 @@ algorithm,
 a variant of partition-exchange sorting; in particular, see D.E. Knuth's
 Algorithm Q.
 .Fn qsort
-takes O N lg N average time.
+takes O(n log n) average time.
 This implementation uses median selection to avoid its
-O N**2 worst-case behavior.
+O(n**2) worst-case behavior.
 .Pp
 The
 .Fn heapsort
@@ -120,7 +120,7 @@ function is an implementation of J.W.J. 
 algorithm,
 a variant of selection sorting; in particular, see D.E. Knuth's Algorithm H.
 .Fn heapsort
-takes O N lg N worst-case time.
+takes O(n log n) worst-case time.
 This implementation of
 .Fn heapsort
 is implemented without recursive function calls.
@@ -133,7 +133,7 @@ requires additional memory of size
 bytes; it should be used only when space is not at a premium.
 .Fn mergesort
 is optimized for data with pre-existing order; its worst case
-time is O N lg N; its best case is O N.
+time is O(n log n); its best case is O(n).
 .Pp
 Normally,
 .Fn qsort


Re: qsort.3 big O notation

2015-03-03 Thread frantisek holop
Ted Unangst, 03 Mar 2015 11:13:
 frantisek holop wrote:
  
  i was looking at the qsort(3) man page,
  and saw O N lg N, etc.
  
  first i thought, maybe there should be some fancy utf8
  math parentheses around, but looking at the source, no,
  it's plain ascii.
  
  a quick search in other man pages reveals an arguably
  more readable style:
  
  ./share/man/man3/queue.3:overhead at the expense of O(n) removal for 
  arbitrary elements.
  ./share/man/man3/tree.3:and n inserts on an initially empty tree as O((m + 
  n)lg n).
  ./share/man/man3/tree.3:The amortized cost for a sequence of m accesses to 
  a splay tree is O(lg n).
  ./share/man/man3/tree.3:Every operation on a red-black tree is bounded as 
  O(lg n).
  ./share/man/man5/pf.conf.5:If there are 50 rules, all of them are evaluated 
  sequentially in O(n).
  ./share/man/man5/pf.conf.5:searches in O(log2 n).
  
  
  i leave the battle about lg vs log to others,
  but i prefer 'log' as there is a man page for that
  and there is none for 'lg'...
 
 If that's the argument to be made, it should be log2 as in pf.conf.

oops.  (my compsci classes were in another millenium)

-f
-- 
if practice makes perfect, and nobody's perfect, why practice?



Re: qsort.3 big O notation

2015-03-03 Thread frantisek holop
Joerg Sonnenberger, 03 Mar 2015 17:28:
 On Tue, Mar 03, 2015 at 05:02:39PM +0100, frantisek holop wrote:
  i leave the battle about lg vs log to others,
  but i prefer 'log' as there is a man page for that
  and there is none for 'lg'...
 
 If anything, it should be log because that is the name of the
 mathematical function. libm is completely irrelevant in this context.

'lg' is also a valid name
(altough i admit i didn't know, i was used to log2)
https://en.wikipedia.org/wiki/Logarithm#Particular_bases

as Tedu pointed out lg = log2 and lg != log

but i think my point is still kind of valid,
as there is log2(3) and no lg(3).

i find it relevant that libm should also use
the most common, easiest names where possible...
it is kind of nice to be able to do 'man log2'
after reading 'man qsort', a kind of indirect
cross reference.

-f
-- 
illiterate?  write for a free brochure!



Re: qsort.3 big O notation

2015-03-03 Thread frantisek holop
Liviu Daia, 03 Mar 2015 19:26:
  'lg' is also a valid name
  (altough i admit i didn't know, i was used to log2)
  https://en.wikipedia.org/wiki/Logarithm#Particular_bases
  
  as Tedu pointed out lg = log2 and lg != log
 
 Actually, that isn't what Tedu said, and it isn't the generally
 accepted convention.  The usual convention is:

my mistake.

 * log = ln = log_e
 * lg = log_10
 
 As somebody else points out, they differ from each other by
 multiplicative constants, so either are correct for O-notation.
 
 (Full disclosure: I'm a mathematician. :))

yes, these are the ISO notations from that wikipedia page.
that Other notations for binary are quite liberal
(ld, log, log2, lg)

if all is the same, then i find 'log' the
most readable in a man page.

-f
-- 
all computers wait at the same speed.



bsd.port.mk.5 typo

2015-02-24 Thread frantisek holop
don't dis the distfiles

-f
-- 
philosophy: unintelligible answers to insoluble problems.
Index: ./share/man/man5/bsd.port.mk.5
===
RCS file: /cvs/src/share/man/man5/bsd.port.mk.5,v
retrieving revision 1.412
diff -u -p -r1.412 bsd.port.mk.5
--- ./share/man/man5/bsd.port.mk.5  23 Dec 2014 14:05:16 -  1.412
+++ ./share/man/man5/bsd.port.mk.5  24 Feb 2015 11:39:50 -
@@ -1198,7 +1198,7 @@ Defaults to empty, set to
 .Pa /cdrom/distfiles/${DIST_SUBDIR}
 to check that path.
 Distribution files are still copied or linked (see
-.Ev FETCH_SYMLINK_DISFILES )
+.Ev FETCH_SYMLINK_DISTFILES )
 into
 .Ev DISTDIR
 if they are found under CDROM_SITE.


add usbdevs vendor

2014-12-29 Thread frantisek holop
noname/rebranded usb composite device (kbd+mouse):

Controller /dev/usb1:
addr 1: full speed, self powered, config 1, UHCI root hub(0x), 
Intel(0x8086), rev 1.00
 port 2 addr 3: full speed, power 100 mA, config 1, 2.4G Receiver(0x5a66), 
vendor 0x1d57(0x1d57), rev 1.10


Index: usbdevs
===
RCS file: /cvs/src/sys/dev/usb/usbdevs,v
retrieving revision 1.641
diff -u -p -r1.641 usbdevs
--- usbdevs 4 Dec 2014 10:41:42 -   1.641
+++ usbdevs 29 Dec 2014 14:15:32 -
@@ -594,6 +594,7 @@ vendor LONGCHEER0x1c9e  Longcheer Techno
 vendor DRESDENELEC 0x1cf1  Dresden Elektronic
 vendor DREAMLINK   0x1d34  Dream Link
 vendor PEGATRON0x1d4d  Pegatron
+vendor XENTA   0x1d57  Xenta
 vendor METAGEEK0x1dd5  MetaGeek
 vendor FESTO   0x1e29  Festo
 vendor MODACOM 0x1eb8  Modacom



-f
-- 
never trust a person who says, trust me



page fault at resume, possibly caused by java/jenkins

2014-12-11 Thread frantisek holop

i think this page fault is triggered by jenkins
during resume.

login: kernel: page fault trap, code=0
Stopped at  in_selectsrc+0xd8:  movl 0xf0(%esi),%ebx
ddb{0} trace
in_selectsrc(f617cdc8,d80b6714,d35d9270,d8cfac44,d8cfac34) at in_selectsrc+0xd8

udp_output(d8cfabfc,d80b6900,d80b6700,0,0) at udp_output+0xf8
sosend(d7f881c8,d80b6700,f617ce90,d80b6900,0) at sosend+0x44b
sendit(d84f4b40,103,f617cef4,0,f617cf80) at sendit+0x1e1
sys_sendto(d84f4b40,f617cf60,f617cf80,d0568b5a,d84f4b40) at sys_sendto+0x6c
syscall() at syscall+0x144
--- syscall (number 259) ---
0x2:
ddb{0}


screenshots:
obiit.org/f/pagefault0.jpg
obiit.org/f/pagefault1.jpg

the running java process is jenkins.
i cannot reproduce it all the time, but now it has
happened twice: suspend at the end of the day,
go to sleep, next day resume, page fault.
both times when i was using jenkins.

i can provide more information when it happens again,
just let me know what exactly...

-f
-- 
let me show you the world in my eyes.



Re: page fault at resume, possibly caused by java/jenkins

2014-12-11 Thread frantisek holop
Martin Pieuchot, 11 Dec 2014 11:59:
 On 11/12/14(Thu) 11:31, frantisek holop wrote:
  i think this page fault is triggered by jenkins
  during resume.
  login: kernel: page fault trap, code=0
  Stopped at  in_selectsrc+0xd8:  movl 0xf0(%esi),%ebx
  ddb{0} trace
  in_selectsrc(f617cdc8,d80b6714,d35d9270,d8cfac44,d8cfac34) at 
  in_selectsrc+0xd8
  
  udp_output(d8cfabfc,d80b6900,d80b6700,0,0) at udp_output+0xf8
  sosend(d7f881c8,d80b6700,f617ce90,d80b6900,0) at sosend+0x44b
  sendit(d84f4b40,103,f617cef4,0,f617cf80) at sendit+0x1e1
  sys_sendto(d84f4b40,f617cf60,f617cf80,d0568b5a,d84f4b40) at sys_sendto+0x6c
  syscall() at syscall+0x144
  --- syscall (number 259) ---
  0x2:
  ddb{0}
  
  
  screenshots:
  obiit.org/f/pagefault0.jpg
  obiit.org/f/pagefault1.jpg
  
  the running java process is jenkins.
  i cannot reproduce it all the time, but now it has
  happened twice: suspend at the end of the day,
  go to sleep, next day resume, page fault.
  both times when i was using jenkins.
  
  i can provide more information when it happens again,
  just let me know what exactly...
 
 Well... what's your dmesg?

sorry. attached.

 What's your network configuration, more explicitly are you using any USB
 device and how? 
 
 What kind of test is jenkins running?  How is it multicast related?

run0 usb dongle + dhclient through a home router,
with one special route added that is forwarded through
a linux box (on the same home router network) which
is connected to a vpn in a different country.
it is added like this:

# route add 192.168.10.2 $LINUX_IP

jenkins is running a shell script, that is running
tests on the 192.168.10.2 web site accessible only
through the vpn.  the tests are simple selenium tests
recorded through the firefox plugin.  a quick google
reveals that jenkins itself might be using some
udp/multicast functionality:
https://wiki.jenkins-ci.org/display/JENKINS/Auto-discovering+Jenkins+on+the+network

-f


OpenBSD 5.6-current (GENERIC.MP) #598: Tue Dec  9 00:45:47 MST 2014
dera...@i386.openbsd.org:/usr/src/sys/arch/i386/compile/GENERIC.MP
cpu0: Intel(R) Core(TM) Duo CPU L2400 @ 1.66GHz (GenuineIntel 686-class) 1.67 
GHz
cpu0: 
FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,NXE,SSE3,MWAIT,VMX,EST,TM2,xTPR,PDCM,PERF
real mem  = 2137341952 (2038MB)
avail mem = 2090082304 (1993MB)
mpath0 at root
scsibus0 at mpath0: 256 targets
mainbus0 at root
bios0 at mainbus0: AT/286+ BIOS, date 03/31/11, BIOS32 rev. 0 @ 0xfd690, SMBIOS 
rev. 2.4 @ 0xe0010 (67 entries)
bios0: vendor LENOVO version 7BETD8WW (2.19 ) date 03/31/2011
bios0: LENOVO 1705CTO
acpi0 at bios0: rev 2
acpi0: sleep states S0 S3 S4 S5
acpi0: tables DSDT FACP SSDT ECDT TCPA APIC MCFG HPET SLIC BOOT SSDT SSDT SSDT 
SSDT
acpi0: wakeup devices LID_(S3) SLPB(S3) DURT(S3) EXP0(S4) EXP1(S4) EXP2(S4) 
EXP3(S4) PCI1(S4) USB0(S3) USB1(S3) USB2(S3) USB7(S3) HDEF(S4)
acpitimer0 at acpi0: 3579545 Hz, 24 bits
acpiec0 at acpi0
acpimadt0 at acpi0 addr 0xfee0: PC-AT compat
cpu0 at mainbus0: apid 0 (boot processor)
mtrr: Pentium Pro MTRR support, 8 var ranges, 88 fixed ranges
cpu0: apic clock running at 166MHz
cpu0: mwait min=64, max=64, C-substates=0.2.2.2.2, IBE
cpu1 at mainbus0: apid 1 (application processor)
cpu1: Intel(R) Core(TM) Duo CPU L2400 @ 1.66GHz (GenuineIntel 686-class) 1.67 
GHz
cpu1: 
FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,NXE,SSE3,MWAIT,VMX,EST,TM2,xTPR,PDCM,PERF
ioapic0 at mainbus0: apid 1 pa 0xfec0, version 20, 24 pins
ioapic0: misconfigured as apic 2, remapped to apid 1
acpimcfg0 at acpi0 addr 0xf000, bus 0-63
acpihpet0 at acpi0: 14318179 Hz
acpiprt0 at acpi0: bus 0 (PCI0)
acpiprt1 at acpi0: bus -1 (AGP_)
acpiprt2 at acpi0: bus 2 (EXP0)
acpiprt3 at acpi0: bus 3 (EXP1)
acpiprt4 at acpi0: bus 4 (EXP2)
acpiprt5 at acpi0: bus 12 (EXP3)
acpiprt6 at acpi0: bus 21 (PCI1)
acpicpu0 at acpi0: C3, C2, C1, PSS
acpicpu1 at acpi0: C3, C2, C1, PSS
acpipwrres0 at acpi0: PUBS, resource for USB0, USB2, USB7
acpitz0 at acpi0: critical temperature is 127 degC
acpitz1 at acpi0: critical temperature is 97 degC
acpibtn0 at acpi0: LID_
acpibtn1 at acpi0: SLPB
acpibat0 at acpi0: BAT0 model 42T4629 serial   327 type LION oem SANYO
acpibat1 at acpi0: BAT1 not present
acpibat2 at acpi0: BAT2 not present
acpiac0 at acpi0: AC unit online
acpithinkpad0 at acpi0
acpidock0 at acpi0: GDCK not docked (0)
bios0: ROM list: 0xc/0xea00! 0xcf000/0x1000 0xd/0x1000 0xdc000/0x4000! 
0xe/0x1!
cpu0: Enhanced SpeedStep 1663 MHz: speeds: 1667, 1333, 1000 MHz
pci0 at mainbus0 bus 0: configuration mode 1 (bios)
pchb0 at pci0 dev 0 function 0 Intel 82945GM Host rev 0x03
vga1 at pci0 dev 2 function 0 Intel 82945GM Video rev 0x03
intagp0 at vga1
agp0 at intagp0: aperture at 0xd000, size 0x1000
inteldrm0 at vga1
drm0 at inteldrm0
inteldrm0: 1024x768
wsdisplay0 at vga1 mux 1: console (std, vt100 emulation)
wsdisplay0: screen

string.h __POSIX_VISIBLE

2014-07-27 Thread frantisek holop
is there a reason why this check should be done twice?

/usr/include/string.h:117:

#if __POSIX_VISIBLE = 200809
char*stpcpy(char *__restrict, const char *__restrict);
char*stpncpy(char *__restrict, const char *__restrict, size_t);
char*strndup(const char *, size_t);
size_t   strnlen(const char *, size_t);
#endif

#if __POSIX_VISIBLE = 200809
char*strsignal(int);
#endif

-f
-- 
when in doubt stop thinking and all doubt will go away.
Index: string.h
===
RCS file: /cvs/src/include/string.h,v
retrieving revision 1.28
diff -u -p -r1.28 string.h
--- string.h13 Jun 2014 02:12:17 -  1.28
+++ string.h27 Jul 2014 16:10:56 -
@@ -119,9 +119,6 @@ char*stpcpy(char *__restrict, const cha
 char   *stpncpy(char *__restrict, const char *__restrict, size_t);
 char   *strndup(const char *, size_t);
 size_t  strnlen(const char *, size_t);
-#endif
-
-#if __POSIX_VISIBLE = 200809
 char   *strsignal(int);
 #endif
 


Re: network autoconfig

2014-07-13 Thread frantisek holop
hmm, on Sun, Jul 13, 2014 at 05:37:51PM +0200, Denis Fondras said that
  
  from the user's PoV, there shouldn't be more needed than
ifconfig if inet autoconf
ifconfig if inet6 autoconf
  aka inet/inet6 autoconf in hostname.if.
  
 
 I'm curious to see what will come out of it as I cannot envision any
 added value of these autoconf compared to dhclient.

sounds like a great place to deal with wifi networks.

-f
-- 
lsd will make your cga screen display 16.2 million colors



Re: network autoconfig

2014-07-13 Thread frantisek holop
hmm, on Sun, Jul 13, 2014 at 02:21:06PM -0400, Brad Smith said that
 On 13/07/14 2:16 PM, frantisek holop wrote:
 hmm, on Sun, Jul 13, 2014 at 05:37:51PM +0200, Denis Fondras said that
 
 from the user's PoV, there shouldn't be more needed than
ifconfig if inet autoconf
ifconfig if inet6 autoconf
 aka inet/inet6 autoconf in hostname.if.
 
 
 I'm curious to see what will come out of it as I cannot envision any
 added value of these autoconf compared to dhclient.
 
 sounds like a great place to deal with wifi networks.
 
 That comment doesn't even make any sense. Wifi networks
 are not magic unicorns.

that little userland daemon, let's call it autoconfd
could have a privsepped part doing scans and
could make a decision how to set up the wifi interface
before dhclient is called.  i can dream, can't i?

-f
-- 
there is never sunshine without shadow.



quick typo in /sys/sys/disklabel.h

2013-11-03 Thread frantisek holop

--- disklabel.h.origSat Nov  2 18:48:46 2013
+++ disklabel.h Sat Nov  2 18:49:51 2013
@@ -43,7 +43,7 @@
  * disk geometry, filesystem partitions, and drive specific information.
  * The location of the label, as well as the number of partitions the
  * label can describe and the number of the whole disk (raw)
- * paritition are machine dependent.
+ * partition are machine dependent.
  */
 #include machine/disklabel.h
 

-f
-- 
pi seconds is a nanocentury.



Re: d-link usb wifi device ids

2013-09-29 Thread frantisek holop
hmm, on Sun, Sep 29, 2013 at 03:59:32PM +1000, Jonathan Gray said that
  for what it's worth here is a small patch for usbdevs:
 
 You obviously didn't try compiling this, it will break all of the
 references to MELCO devices in the kernel.

guilty as charged.
(also a good thing this time, as the change would not happen ;-)

i resubmit only the device id addition, however these changes
seem now superfluous to me, as at the moment neither usbdevs(8)
nor the kernel will ever show them...


Index: usbdevs
===
RCS file: /cvs/src/sys/dev/usb/usbdevs,v
retrieving revision 1.605
diff -u -p -r1.605 usbdevs
--- usbdevs 5 Sep 2013 19:42:09 -   1.605
+++ usbdevs 29 Sep 2013 06:07:11 -
@@ -1457,6 +1457,7 @@ product DLINK RT2570  0x3c00  RT2570
 product DLINK DUBE100B10x3c05  DUB-E100 rev B1
 product DLINK RT2870   0x3c09  RT2870
 product DLINK RT3072   0x3c0a  RT3072
+product DLINK DWA125A3 0x3c19  DWA-125 rev A3
 product DLINK DSB650C  0x4000  10Mbps Ethernet
 product DLINK DSB650TX10x4001  10/100 Ethernet
 product DLINK DSB650TX 0x4002  10/100 Ethernet


-f
-- 
nothing can go wrong now, go wrong, gow rong, grong!



d-link usb wifi device ids

2013-09-28 Thread frantisek holop
hi there,

after inserting this D-LINK DWA-125 rev A3 usb wifi, i get:

ugen1 at uhub0 port 6 Ralink 11n Adapter rev 2.00/1.01 addr 5

which is kind of true, as it is supposed to be
powered by Ralink RT5370.  but according to
/sys/dev/usb/usbdevs, 0x2001 is DLINK and 0x3c19 is not even in there.

to add more to my confusion usbdevs -v shows:

$ usbdevs -v | grep Ralink
 port 2 addr 2: high speed, power 450 mA, config 1, 802.11 n WLAN(0x01a2), 
Ralink(0x0411), rev 1.01, iSerialNumber 1.0
 port 6 addr 5: high speed, power 450 mA, config 1, 11n Adapter(0x3c19), 
Ralink(0x2001), rev 1.01, iSerialNumber 1.0

what is that other device?

-f
-- 
computers run on smoke. if it leaks out they won't work.



Re: d-link usb wifi device ids

2013-09-28 Thread frantisek holop
hmm, on Sat, Sep 28, 2013 at 12:25:27PM +0100, Stuart Henderson said that
 On 2013/09/28 11:34, frantisek holop wrote:
  hi there,
  
  after inserting this D-LINK DWA-125 rev A3 usb wifi, i get:
  
  ugen1 at uhub0 port 6 Ralink 11n Adapter rev 2.00/1.01 addr 5
  
  which is kind of true, as it is supposed to be
  powered by Ralink RT5370.  but according to
  /sys/dev/usb/usbdevs, 0x2001 is DLINK and 0x3c19 is not even in there.
 
 Normally, strings for USB devices come from the device itself, iirc the kernel
 strings are used when the device has no string.
 
  to add more to my confusion usbdevs -v shows:
  
  $ usbdevs -v | grep Ralink
   port 2 addr 2: high speed, power 450 mA, config 1, 802.11 n WLAN(0x01a2), 
  Ralink(0x0411), rev 1.01, iSerialNumber 1.0
   port 6 addr 5: high speed, power 450 mA, config 1, 11n Adapter(0x3c19), 
  Ralink(0x2001), rev 1.01, iSerialNumber 1.0
  
  what is that other device?
 
 Any more clues from lsusb -v ?

well, the other device, that is of course my working,
other usb wifi dongle..  what threw me completely off was
that 0x0411 is Melco, the device itself is a Buffalo,
and it is shown as Ralink...

lsusb cleared that one up:

Bus 000 Device 002: ID 0411:01a2 BUFFALO INC. (formerly MelCo., Inc.) 
WLI-UC-GNM Wireless LAN Adapter
Device Descriptor:
  idVendor   0x0411 BUFFALO INC. (formerly MelCo., Inc.)
  idProduct  0x01a2 WLI-UC-GNM Wireless LAN Adapter
  iManufacturer   1 Ralink
  iProduct2 802.11 n WLAN
  iSerial 3 1.0


the D-Link device shows up as:

Bus 000 Device 005: ID 2001:3c19 D-Link Corp. 
Device Descriptor:
  idVendor   0x2001 D-Link Corp.
  idProduct  0x3c19 
  iManufacturer   1 Ralink
  iProduct2 11n Adapter
  iSerial 3 1.0


so iManufacturer and iProduct override usbdevs device ids.  i personally
find this kind of confusing, and i think it dilutes the value of dmesgs.
usbdevs(8) output is outright lying to me.  i think it should make a
disctinction between usbdevs id and iManufacturer.  in my case, i have 2
totally different devices but according to dmesg they are basically the
same, Ralink 11n Adapter and Ralink 802.11 n WLAN.

for what it's worth here is a small patch for usbdevs:


Index: usbdevs
===
RCS file: /cvs/src/sys/dev/usb/usbdevs,v
retrieving revision 1.605
diff -u -p -r1.605 usbdevs
--- usbdevs 5 Sep 2013 19:42:09 -   1.605
+++ usbdevs 29 Sep 2013 05:34:07 -
@@ -68,7 +68,7 @@ vendor QUANTA20x0408  Quanta
 vendor NEC 0x0409  NEC
 vendor KODAK   0x040a  Eastman Kodak
 vendor VIA 0x040d  VIA
-vendor MELCO   0x0411  Melco
+vendor BUFFALO 0x0411  Buffalo
 vendor LEADTEK 0x0413  Leadtek
 vendor CREATIVE0x041e  Creative Labs
 vendor NOKIA2  0x0421  Nokia
@@ -1457,6 +1457,7 @@ product DLINK RT2570  0x3c00  RT2570
 product DLINK DUBE100B10x3c05  DUB-E100 rev B1
 product DLINK RT2870   0x3c09  RT2870
 product DLINK RT3072   0x3c0a  RT3072
+product DLINK DWA125A3 0x3c19  DWA-125 rev A3
 product DLINK DSB650C  0x4000  10Mbps Ethernet
 product DLINK DSB650TX10x4001  10/100 Ethernet
 product DLINK DSB650TX 0x4002  10/100 Ethernet


-f
-- 
monday: in christian countries, the day after the footbal.



Re: ntpd jump ahead

2013-09-19 Thread frantisek holop
hmm, on Fri, Sep 06, 2013 at 07:42:39AM -0400, Nick Holland said that
 On 09/06/13 04:50, Stuart Henderson wrote:
  On 2013/09/05 20:03, Barry Grumbine wrote:
  Non-VM use case: The BeagleBone Black has no RTC, so -j could be
  useful for cheap little ARM development boards.
  
  -s is fine for that (and the same for those of the alix boards with
  no rtc battery, etc).
  
 
 ...unless the machine isn't attached to the network when initially
 powered up.
 
 Same goes for any machine with a dead RTC battery that may not have a
 good network connection at boot, and/or you don't want to slow the boot
 down by 15 seconds if there is no network connection.  This shocks
 people, but I often use a computer where there is no network connection.
  Waiting for that 15 second boot delay is annoying.

a quick and dirty solution could be rdate(8) in crontab(5)

-f
-- 
i am not a dictator.  it's just i have a grumpy face.



Re: tmux and login shells

2012-06-22 Thread frantisek holop
hmm, on Thu, Jun 21, 2012 at 08:11:19PM +0100, Stuart Henderson said that
 On 2012/06/21 15:52, Daniel Bolgheroni wrote:
  On Thu, Jun 21, 2012 at 04:21:30PM +0100, Nicholas Marriott wrote:
  
   I'm afraid tmux defaults are never going to please everyone. Some even
   had the gall to hate on the nice green status line ;-).
  
  Oh, the green... I should have mentioned this...
  
  I don't want to bikeshed[1], but colors are never good for whatever
  'default' on cli software. But this is just *imho*.
  
  [1] 
  http://www.freebsd.org/doc/en_US.ISO8859-1/books/faq/misc.html#BIKESHED-PAINTING
  
 
 If you don't like colours, it's probably best to use a monochrome
 terminal type (e.g. TERM=xtermm)...

looks like it's time to have a new colorls flame war again :]

-f
-- 
apple (c) copyright 1767, sir isaac newton.



Re: pkg_add interactive prompts

2011-05-17 Thread frantisek holop
hmm, on Tue, May 17, 2011 at 11:38:09PM +0200, Matthias Kilian said that
 On Tue, May 17, 2011 at 11:00:01PM +0200, frantisek holop wrote:
  (my rationale for removing the option 0: None is that
  i have asked for the package, so why would i choose None?
  i can always ctrl-c out if i have changed my mind...)
 
 AFAIK, ambiguous packages can also happen during updates (pkg_add
 -ui), for example if an updated package has a new dependency on
 another package that's available in different flavors. You don't

in that case, isn't the dependency menu shown? (with no None)

as i understand it, dependencies are not optional,
one FLAVOR must be chosen if something depends on it.

-f
-- 
what good grammar you got.  what school you went?



Re: dhclient-script and resolv.conf

2010-12-26 Thread frantisek holop
hmm, on Wed, Dec 15, 2010 at 04:08:23PM +0100, Claudio Jeker said that
 This made me go nuts for a long time. As soon as you have two interfaces
 running dhclient those two will start fighting over /etc/resolv.conf
 which is realy bad when short lease times are used and one interface is
 not getting new leases.

also, do you know of a good way to modify the order of the interfaces?
(besides the alphabet ;-)

-f
-- 
if you can't see black, white has no meaning



Re: Automatic package mirror discovery implementation for pkg_add(1) tool

2010-02-21 Thread frantisek holop
hmm, on Thu, Feb 11, 2010 at 12:35:05AM +0300, Igor Zinovik said that
 Maybe it is not polite to answer to this old thread, but I've integrated
 (somehow) AutoMirrorDiscovery functionality into pkg_add tool, just to
 prove myself that i can do that without crashing pkg_add functionality.  It is
 very clumsy right now, but it works for me (with some bugs of course).

this is a great idea i think.
maybe you would want to rename it MirrorAutoDiscovery though :]

i would also fill the cache file with all the mirrors,
(not just the n fastest) in order from fastest to slowest.

if the list of the mirrors is taken from www.openbsd.org
everytime the list is generated, the list could be
considered authoritative.

-f
-- 
go ahead, jump.  100,000 lemmings can't be wrong.



Re: nvidia mcp77 ahci mode patch

2009-10-17 Thread frantisek holop
hmm, on Sat, Oct 17, 2009 at 02:58:59AM +0200, Jonathan Gray said that
 To clarify, when you have the machine in AHCI mode it attaches
 as ahci but port resets prevent devices attached to the controller
 being found?

yes, that is correct.  after applying the AHCI_6 patch
the drives attach.

the notebook spends most of its time in interrupts (80-85%),
but i dont't know if this is related to ahci or not.
beforehand the cpu was doing pio, now interrupts.

$ vmstat -i
interrupt   total rate
irq0/clock  49070   97
irq81/ohci0  12502
irq83/ehci0 20
irq81/ehci1   1580
irq83/azalia0   10
irq82/ahci0  29725
irq83/ral0  13362   26
irq129/pckbc0 7521
irq131/pckbc0   70
Total   67574  134


OpenBSD 4.6-current (GENERIC) #11: Sat Oct 17 06:22:49 CEST 2009
f...@amaaq:/adata/home/f/usr/src/sys/arch/i386/compile/GENERIC
cpu0: AMD Turion(tm) X2 Ultra Dual-Core Mobile ZM-80 (AuthenticAMD 686-class, 
1024KB L2 cache) 2.11 GHz
cpu0: 
FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,CX16
real mem  = 3217104896 (3068MB)
avail mem = 3125399552 (2980MB)
User Kernel Config
UKC disable acpicpu
474 acpicpu* disabled
UKC quit
Continuing...
mainbus0 at root
bios0 at mainbus0: AT/286+ BIOS, date 02/08/08, SMBIOS rev. 2.4 @ 0xbfb51018 
(53 entries)
bios0: vendor American Megatrends Inc. version E1652NMS VER.106 date 
12/26/2008
bios0: Micro-Star International GX-630
acpi0 at bios0: rev 2
acpi0: tables DSDT FACP APIC SSDT MCFG SLIC
acpi0: wakeup devices PS2K(S4) PS2M(S4) NSMB(S4) USB0(S4) USB2(S3) USB1(S4) 
USB4(S3) NMAC(S5) HDAC(S4) POP2(S4) BR12(S4) BR13(S4) BR14(S4) BR16(S4) 
SLPB(S4) PWRB(S4)
acpitimer0 at acpi0: 3579545 Hz, 24 bits
acpimadt0 at acpi0 addr 0xfee0: PC-AT compat
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: apic clock running at 200MHz
cpu at mainbus0: not configured
ioapic0 at mainbus0: apid 0 pa 0xfec0, version 11, 24 pins
acpiprt0 at acpi0: bus 0 (PCI0)
acpiprt1 at acpi0: bus 3 (BR12)
acpiprt2 at acpi0: bus 4 (BR13)
acpiprt3 at acpi0: bus 5 (BR14)
acpiprt4 at acpi0: bus 8 (BR16)
acpiec0 at acpi0
acpicpu at acpi0 not configured
acpitz0 at acpi0: critical temperature 100 degC
acpiac0 at acpi0: AC unit online
acpibat0 at acpi0: BAT1 model MS-1221
 serial 
 type LION
 oem MSI Corp.

acpibtn0 at acpi0: LID0
acpibtn1 at acpi0: SLPB
acpibtn2 at acpi0: PWRB
acpivideo0 at acpi0: VGA_
acpivout0 at acpivideo0: CRT_
acpivout1 at acpivideo0: LCD_
acpivout2 at acpivideo0: HDMI
bios0: ROM list: 0xc/0xe200 0xce800/0x1800
pci0 at mainbus0 bus 0: configuration mode 1 (bios)
NVIDIA MCP77 Memory rev 0xa2 at pci0 dev 0 function 0 not configured
pcib0 at pci0 dev 1 function 0 NVIDIA MCP77 ISA rev 0xa2
nviic0 at pci0 dev 1 function 1 NVIDIA MCP77 SMBus rev 0xa1
iic0 at nviic0
iic1 at nviic0
spdmem0 at iic1 addr 0x50: 2GB DDR2 SDRAM non-parity PC2-6400CL5 SO-DIMM
spdmem1 at iic1 addr 0x51: 2GB DDR2 SDRAM non-parity PC2-6400CL5 SO-DIMM
NVIDIA MCP77 Co-processor rev 0xa2 at pci0 dev 1 function 3 not configured
NVIDIA MCP77 Memory rev 0xa1 at pci0 dev 1 function 4 not configured
ohci0 at pci0 dev 2 function 0 NVIDIA MCP77 USB rev 0xa1: apic 0 int 7 (irq 
7), version 1.0, legacy support
ehci0 at pci0 dev 2 function 1 NVIDIA MCP77 USB rev 0xa1: apic 0 int 11 (irq 
11)
usb0 at ehci0: USB revision 2.0
uhub0 at usb0 NVIDIA EHCI root hub rev 2.00/1.00 addr 1
ohci1 at pci0 dev 4 function 0 NVIDIA MCP77 USB rev 0xa1: apic 0 int 5 (irq 
5), version 1.0, legacy support
ehci1 at pci0 dev 4 function 1 NVIDIA MCP77 USB rev 0xa1: apic 0 int 7 (irq 7)
usb1 at ehci1: USB revision 2.0
uhub1 at usb1 NVIDIA EHCI root hub rev 2.00/1.00 addr 1
pciide0 at pci0 dev 6 function 0 NVIDIA MCP77 IDE rev 0xa1: DMA, channel 0 
configured to compatibility, channel 1 configured to compatibility
pciide0: channel 0 ignored (disabled)
pciide0: channel 1 ignored (disabled)
azalia0 at pci0 dev 7 function 0 NVIDIA MCP77 HD Audio rev 0xa1: apic 0 int 
11 (irq 11)
azalia0: codecs: Realtek ALC888, Motorola/0x3055, NVIDIA/0x0006, using Realtek 
ALC888
audio0 at azalia0
ppb0 at pci0 dev 8 function 0 NVIDIA MCP77 PCI rev 0xa1
pci1 at ppb0 bus 1
ahci0 at pci0 dev 9 function 0 NVIDIA MCP77 AHCI rev 0xa2: apic 0 int 10 (irq 
10), AHCI 1.2
scsibus0 at ahci0: 32 targets
sd0 at scsibus0 targ 0 lun 0: ATA, FUJITSU MHZ2320B,  SCSI3 0/direct fixed
sd0: 305245MB, 512 bytes/sec, 625142448 sec total
cd0 at scsibus0 targ 2 lun 0: Optiarc, DVD RW AD-7560S, SX01 ATAPI 5/cdrom 
removable
nfe0 at pci0 dev 10 function 0 NVIDIA MCP77 LAN rev 0xa2: apic 0 int 5 (irq 
5), address 00:21:85:55:af:d3
eephy0 at nfe0 phy 1: 88E1116 Gigabit PHY, rev. 1
ppb1 at pci0 dev 16 function 0 NVIDIA MCP77 PCIE rev 0xa1: apic 0 int 7 (irq 
7)
pci2 

Re: nvidia mcp77 ahci mode patch

2009-10-16 Thread frantisek holop
hmm, on Fri, Oct 16, 2009 at 08:31:13PM +0200, Jonathan Gray said that
 It sounds like this device should not be referred to
 as AHCI if it attaches to pciide and does not claim
 an AHCI interface.

ok, i guess i wan't clear enough, let me try again.

the notebook is ahci capable.  but i use it in ide mode
at the moment.

the pciide patch is needed, so in ide mode, pciide can
use dma (and not only pio).

the ahci patch makes the disk work in ahci mode when i flip
the switch in the bios to ahci mode. without it i had
port reset messages and the drive is not found.


i dont have the pcidump on me at the moment, but
i looked at its output and it was vendor NVIDIA,
product PCI_PRODUCT_NVIDIA_MCP77_AHCI_1 (0x0ad0).
that's how i found which PCI_PRODUCT_NVIDIA_MCP77_AHCI_?
to add to ahci.c

if both patches are present in the kernel and the disk
is in ide mode, one has to disable ahci in ukc so
the controller attaches to pciide and not ahci.


in an ideal world, probably only the ahci patch would be
needed.  but i also want to be able to use the disk in
ide mode hence the pciide patch.

i can send the pcidump output on monday..

 On Fri, Oct 16, 2009 at 06:34:58AM +0200, frantisek holop wrote:
  hi there,
  
  the following addition makes ahci work on my MCP77.
  if this piece is present together with the ide
  compatibility patch, and the disk is not in ahci
  mode, ahci must be disabled in ukc to force the
  chipset into compatibility mode.
  
  i experimented with both modes because the other
  systems on the disk can't do ahci yet.
  
  just out of curiosity, is there a reason why not all
  PCI_PRODUCT_NVIDIA_MCP*_AHCI_* id's are listed?
  
  
  Index: ahci.c
  ===
  RCS file: /cvs/src/sys/dev/pci/ahci.c,v
  retrieving revision 1.150
  diff -u -r1.150 ahci.c
  --- ahci.c  13 Oct 2009 00:19:38 -  1.150
  +++ ahci.c  16 Oct 2009 04:21:55 -
  @@ -438,6 +438,8 @@
  NULL,   ahci_nvidia_mcp_attach },
  { PCI_VENDOR_NVIDIA,PCI_PRODUCT_NVIDIA_MCP73_AHCI_9,
  NULL,   ahci_nvidia_mcp_attach },
  +   { PCI_VENDOR_NVIDIA,PCI_PRODUCT_NVIDIA_MCP77_AHCI_1,
  +   NULL,   ahci_nvidia_mcp_attach },
  { PCI_VENDOR_NVIDIA,PCI_PRODUCT_NVIDIA_MCP77_AHCI_5,
  NULL,   ahci_nvidia_mcp_attach },
  
  
  the difference between ide mode and ahci mode:
  
  --- dmesg.bsd.16Fri Oct 16 05:59:30 2009
  +++ dmesg.bsd.16.ahci   Fri Oct 16 06:19:52 2009
  @@ -2,14 +2,11 @@
   f...@amaaq:/adata/home/f/usr/src/sys/arch/i386/compile/GENERIC
   cpu0: AMD Turion(tm) X2 Ultra Dual-Core Mobile ZM-80 (AuthenticAMD 
  686-class, 1024KB L2 cache) 2.11 GHz
   cpu0: 
  FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,CX16
  -real mem  = 3217108992 (3068MB)
  -avail mem = 3125407744 (2980MB)
  +real mem  = 3217104896 (3068MB)
  +avail mem = 3125403648 (2980MB)
   User Kernel Config
   UKC disable acpicpu
   474 acpicpu* disabled
   UKC quit
   Continuing...
   mainbus0 at root
  @@ -73,15 +70,11 @@
   audio0 at azalia0
   ppb0 at pci0 dev 8 function 0 NVIDIA MCP77 PCI rev 0xa1
   pci1 at ppb0 bus 1
  -pciide1 at pci0 dev 9 function 0 NVIDIA MCP77 AHCI rev 0xa2: DMA
  -pciide1: using apic 0 int 10 (irq 10) for native-PCI interrupt
  -wd0 at pciide1 channel 0 drive 0: FUJITSU MHZ2320BH G2
  -wd0: 16-sector PIO, LBA48, 305245MB, 625142448 sectors
  -atapiscsi0 at pciide1 channel 0 drive 1
  -scsibus0 at atapiscsi0: 2 targets
  -cd0 at scsibus0 targ 0 lun 0: Optiarc, DVD RW AD-7560S, SX01 ATAPI 
  5/cdrom removable
  -wd0(pciide1:0:0): using PIO mode 4, Ultra-DMA mode 5
  -cd0(pciide1:0:1): using PIO mode 4, Ultra-DMA mode 5
  +ahci0 at pci0 dev 9 function 0 NVIDIA MCP77 AHCI rev 0xa2: apic 0 int 10 
  (irq 10), AHCI 1.2
  +scsibus0 at ahci0: 32 targets
  +sd0 at scsibus0 targ 0 lun 0: ATA, FUJITSU MHZ2320B,  SCSI3 0/direct 
  fixed
  +sd0: 305245MB, 512 bytes/sec, 625142448 sec total
  +cd0 at scsibus0 targ 2 lun 0: Optiarc, DVD RW AD-7560S, SX01 ATAPI 
  5/cdrom removable
   nfe0 at pci0 dev 10 function 0 NVIDIA MCP77 LAN rev 0xa2: apic 0 int 5 
  (irq 5), address 00:21:85:55:af:d3
   eephy0 at nfe0 phy 1: 88E1116 Gigabit PHY, rev. 1
   ppb1 at pci0 dev 16 function 0 NVIDIA MCP77 PCIE rev 0xa1: apic 0 int 7 
  (irq 7)
  @@ -149,4 +142,4 @@
   vscsi0 at root
   scsibus2 at vscsi0: 256 targets
   softraid0 at root
  -root on wd0a swap on wd0b dump on wd0b
  +root on sd0a swap on sd0b dump on sd0b
  
  
  -f
  -- 
  go and catch a falling star...

-- 
a kick in the ass is a step forward.



NVIDIA pci id's patch

2009-10-15 Thread frantisek holop
hi there,

the following patch adds the GeForce 9600M GT,
sorts the id's by id numbers, and adds a missing
underscore.

also, according to pcidatabase.com, 0x084b is not
an exotic version of GEFORCE_9300_GE_2 but
GeForce 8200 so make 9300_GE uniq again.


Index: pcidevs
===
RCS file: /cvs/src/sys/dev/pci/pcidevs,v
retrieving revision 1.1498
diff -u -r1.1498 pcidevs
--- pcidevs 5 Oct 2009 17:00:24 -   1.1498
+++ pcidevs 15 Oct 2009 16:44:08 -
@@ -3989,9 +3989,10 @@
 product NVIDIA MCP73_PPB_2 0x056e  MCP73 PCIE
 product NVIDIA MCP73_PPB_3 0x056f  MCP73 PCIE
 product NVIDIA GEFORCE_9800_GTX0x0605  GeForce 9800 GTX
-product NVIDIA GEFORCE_9300_GE_1   0x06e0  GeForce 9300 GE
 product NVIDIA GEFORCE_9600_GT 0x0622  GeForce 9600 GT
-product NVIDIA GEFORCE9300M_GS 0x06e9  GeForce 9300M GS
+product NVIDIA GEFORCE_9600M_GT0x0649  GeForce 9600M GT
+product NVIDIA GEFORCE_9300_GE 0x06e0  GeForce 9300 GE
+product NVIDIA GEFORCE_9300M_GS0x06e9  GeForce 9300M GS
 product NVIDIA MCP77_MEM2  0x0751  MCP77 Memory
 product NVIDIA MCP77_SMB   0x0752  MCP77 SMBus
 product NVIDIA MCP77_COPROC0x0753  MCP77 Co-processor
@@ -4055,7 +4056,7 @@
 product NVIDIA MCP73_HDA_1 0x07fc  MCP73 HD Audio
 product NVIDIA MCP73_HDA_2 0x07fd  MCP73 HD Audio
 product NVIDIA MCP73_OHCI  0x07fe  MCP73 USB
-product NVIDIA GEFORCE_9300_GE_2   0x084b  GeForce 9300 GE
+product NVIDIA GEFORCE_82000x084b  GeForce 8200
 product NVIDIA GEFORCE_93000x086c  GeForce 9300
 product NVIDIA MCP79_HB_1  0x0a80  MCP79 Host
 product NVIDIA MCP79_HB_2  0x0a81  MCP79 Host


-f
-- 
breeding rabbits is a hare raising experience.



nvidia mcp77 ide mode patch

2009-10-15 Thread frantisek holop
hi there

the following patch allows the MCP77 to use DMA mode
when in ide compatibility mode:

Index: pciide.c
===
RCS file: /cvs/src/sys/dev/pci/pciide.c,v
retrieving revision 1.302
diff -u -r1.302 pciide.c
--- pciide.c13 Oct 2009 22:05:13 -  1.302
+++ pciide.c16 Oct 2009 03:24:42 -
@@ -994,6 +994,10 @@
  0,
  nforce_chip_map
},
+   { PCI_PRODUCT_NVIDIA_MCP77_AHCI_1,
+ 0,
+ sata_chip_map
+   },
{ PCI_PRODUCT_NVIDIA_NFORCE2_400_SATA,
  0,
  sata_chip_map


--- dmesg.bsd.15Fri Oct 16 05:30:46 2009
+++ dmesg.bsd.16Fri Oct 16 05:59:30 2009
@@ -1,12 +1,15 @@
-OpenBSD 4.6-current (GENERIC) #296: Tue Oct 13 12:12:59 MDT 2009
-dera...@i386.openbsd.org:/usr/src/sys/arch/i386/compile/GENERIC
+OpenBSD 4.6-current (GENERIC) #10: Fri Oct 16 05:48:16 CEST 2009
+f...@amaaq:/adata/home/f/usr/src/sys/arch/i386/compile/GENERIC
 cpu0: AMD Turion(tm) X2 Ultra Dual-Core Mobile ZM-80 (AuthenticAMD 
686-class, 1024KB L2 cache) 2.11 GHz
 cpu0: 
FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,CX16
 real mem  = 3217108992 (3068MB)
-avail mem = 3125432320 (2980MB)
+avail mem = 3125407744 (2980MB)
 User Kernel Config
 UKC disable acpicpu
 474 acpicpu* disabled
 UKC quit
 Continuing...
 mainbus0 at root
@@ -70,19 +73,20 @@
 audio0 at azalia0
 ppb0 at pci0 dev 8 function 0 NVIDIA MCP77 PCI rev 0xa1
 pci1 at ppb0 bus 1
-pciide1 at pci0 dev 9 function 0 NVIDIA MCP77 AHCI rev 0xa2: DMA 
(unsupported), channel 0 wired to native-PCI, channel 1 wired to native-PCI
+pciide1 at pci0 dev 9 function 0 NVIDIA MCP77 AHCI rev 0xa2: DMA
 pciide1: using apic 0 int 10 (irq 10) for native-PCI interrupt
 wd0 at pciide1 channel 0 drive 0: FUJITSU MHZ2320BH G2
 wd0: 16-sector PIO, LBA48, 305245MB, 625142448 sectors
 atapiscsi0 at pciide1 channel 0 drive 1
 scsibus0 at atapiscsi0: 2 targets
 cd0 at scsibus0 targ 0 lun 0: Optiarc, DVD RW AD-7560S, SX01 ATAPI 5/cdrom 
removable
-pciide1: channel 1 ignored (not responding; disabled or no drives?)
+wd0(pciide1:0:0): using PIO mode 4, Ultra-DMA mode 5
+cd0(pciide1:0:1): using PIO mode 4, Ultra-DMA mode 5
 nfe0 at pci0 dev 10 function 0 NVIDIA MCP77 LAN rev 0xa2: apic 0 int 5 (irq 
5), address 00:21:85:55:af:d3
 eephy0 at nfe0 phy 1: 88E1116 Gigabit PHY, rev. 1
 ppb1 at pci0 dev 16 function 0 NVIDIA MCP77 PCIE rev 0xa1: apic 0 int 7 (irq 
7)

full dmesg (with MCP77 being disabled):

OpenBSD 4.6-current (GENERIC) #10: Fri Oct 16 05:48:16 CEST 2009
f...@amaaq:/adata/home/f/usr/src/sys/arch/i386/compile/GENERIC
cpu0: AMD Turion(tm) X2 Ultra Dual-Core Mobile ZM-80 (AuthenticAMD 686-class, 
1024KB L2 cache) 2.11 GHz
cpu0: 
FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,CX16
real mem  = 3217108992 (3068MB)
avail mem = 3125407744 (2980MB)
User Kernel Config
UKC disable acpicpu
474 acpicpu* disabled
UKC quit
Continuing...
mainbus0 at root
bios0 at mainbus0: AT/286+ BIOS, date 02/08/08, SMBIOS rev. 2.4 @ 0xbfb51018 
(53 entries)
bios0: vendor American Megatrends Inc. version E1652NMS VER.106 date 
12/26/2008
bios0: Micro-Star International GX-630
acpi0 at bios0: rev 2
acpi0: tables DSDT FACP APIC SSDT MCFG SLIC
acpi0: wakeup devices PS2K(S4) PS2M(S4) NSMB(S4) USB0(S4) USB2(S3) USB1(S4) 
USB4(S3) NMAC(S5) HDAC(S4) POP2(S4) BR12(S4) BR13(S4) BR14(S4) BR16(S4) 
SLPB(S4) PWRB(S4)
acpitimer0 at acpi0: 3579545 Hz, 24 bits
acpimadt0 at acpi0 addr 0xfee0: PC-AT compat
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: apic clock running at 200MHz
cpu at mainbus0: not configured
ioapic0 at mainbus0: apid 0 pa 0xfec0, version 11, 24 pins
acpiprt0 at acpi0: bus 0 (PCI0)
acpiprt1 at acpi0: bus 3 (BR12)
acpiprt2 at acpi0: bus 4 (BR13)
acpiprt3 at acpi0: bus 5 (BR14)
acpiprt4 at acpi0: bus 8 (BR16)
acpiec0 at acpi0
acpicpu at acpi0 not configured
acpitz0 at acpi0: critical temperature 100 degC
acpiac0 at acpi0: AC unit online
acpibat0 at acpi0: BAT1 model MS-1221
 serial 
 type LION
 oem MSI Corp.

acpibtn0 at acpi0: LID0
acpibtn1 at acpi0: SLPB
acpibtn2 at acpi0: PWRB
acpivideo0 at acpi0: VGA_
acpivout0 at acpivideo0: CRT_
acpivout1 at acpivideo0: LCD_
acpivout2 at acpivideo0: HDMI
bios0: ROM list: 0xc/0xe200 0xce800/0x1800
pci0 at mainbus0 bus 0: configuration mode 1 (bios)
NVIDIA MCP77 Memory rev 0xa2 at pci0 dev 0 function 0 not configured
pcib0 at pci0 dev 1 function 0 NVIDIA MCP77 ISA rev 0xa2
nviic0 at pci0 dev 1 function 1 NVIDIA MCP77 SMBus rev 0xa1
iic0 at nviic0
iic1 at nviic0
spdmem0 at iic1 addr 0x50: 2GB DDR2 SDRAM non-parity PC2-6400CL5 SO-DIMM
spdmem1 at iic1 addr 0x51: 2GB DDR2 SDRAM non-parity PC2-6400CL5 SO-DIMM
NVIDIA MCP77 Co-processor rev 0xa2 at pci0 dev 1 function 3 not configured
NVIDIA MCP77 Memory rev 0xa1 at pci0 dev 1 function 4 not configured
ohci0 at pci0 dev 2 function 0 NVIDIA MCP77 USB rev 

nvidia mcp77 ahci mode patch

2009-10-15 Thread frantisek holop
hi there,

the following addition makes ahci work on my MCP77.
if this piece is present together with the ide
compatibility patch, and the disk is not in ahci
mode, ahci must be disabled in ukc to force the
chipset into compatibility mode.

i experimented with both modes because the other
systems on the disk can't do ahci yet.

just out of curiosity, is there a reason why not all
PCI_PRODUCT_NVIDIA_MCP*_AHCI_* id's are listed?


Index: ahci.c
===
RCS file: /cvs/src/sys/dev/pci/ahci.c,v
retrieving revision 1.150
diff -u -r1.150 ahci.c
--- ahci.c  13 Oct 2009 00:19:38 -  1.150
+++ ahci.c  16 Oct 2009 04:21:55 -
@@ -438,6 +438,8 @@
NULL,   ahci_nvidia_mcp_attach },
{ PCI_VENDOR_NVIDIA,PCI_PRODUCT_NVIDIA_MCP73_AHCI_9,
NULL,   ahci_nvidia_mcp_attach },
+   { PCI_VENDOR_NVIDIA,PCI_PRODUCT_NVIDIA_MCP77_AHCI_1,
+   NULL,   ahci_nvidia_mcp_attach },
{ PCI_VENDOR_NVIDIA,PCI_PRODUCT_NVIDIA_MCP77_AHCI_5,
NULL,   ahci_nvidia_mcp_attach },


the difference between ide mode and ahci mode:

--- dmesg.bsd.16Fri Oct 16 05:59:30 2009
+++ dmesg.bsd.16.ahci   Fri Oct 16 06:19:52 2009
@@ -2,14 +2,11 @@
 f...@amaaq:/adata/home/f/usr/src/sys/arch/i386/compile/GENERIC
 cpu0: AMD Turion(tm) X2 Ultra Dual-Core Mobile ZM-80 (AuthenticAMD 
686-class, 1024KB L2 cache) 2.11 GHz
 cpu0: 
FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,CX16
-real mem  = 3217108992 (3068MB)
-avail mem = 3125407744 (2980MB)
+real mem  = 3217104896 (3068MB)
+avail mem = 3125403648 (2980MB)
 User Kernel Config
 UKC disable acpicpu
 474 acpicpu* disabled
 UKC quit
 Continuing...
 mainbus0 at root
@@ -73,15 +70,11 @@
 audio0 at azalia0
 ppb0 at pci0 dev 8 function 0 NVIDIA MCP77 PCI rev 0xa1
 pci1 at ppb0 bus 1
-pciide1 at pci0 dev 9 function 0 NVIDIA MCP77 AHCI rev 0xa2: DMA
-pciide1: using apic 0 int 10 (irq 10) for native-PCI interrupt
-wd0 at pciide1 channel 0 drive 0: FUJITSU MHZ2320BH G2
-wd0: 16-sector PIO, LBA48, 305245MB, 625142448 sectors
-atapiscsi0 at pciide1 channel 0 drive 1
-scsibus0 at atapiscsi0: 2 targets
-cd0 at scsibus0 targ 0 lun 0: Optiarc, DVD RW AD-7560S, SX01 ATAPI 5/cdrom 
removable
-wd0(pciide1:0:0): using PIO mode 4, Ultra-DMA mode 5
-cd0(pciide1:0:1): using PIO mode 4, Ultra-DMA mode 5
+ahci0 at pci0 dev 9 function 0 NVIDIA MCP77 AHCI rev 0xa2: apic 0 int 10 
(irq 10), AHCI 1.2
+scsibus0 at ahci0: 32 targets
+sd0 at scsibus0 targ 0 lun 0: ATA, FUJITSU MHZ2320B,  SCSI3 0/direct 
fixed
+sd0: 305245MB, 512 bytes/sec, 625142448 sec total
+cd0 at scsibus0 targ 2 lun 0: Optiarc, DVD RW AD-7560S, SX01 ATAPI 5/cdrom 
removable
 nfe0 at pci0 dev 10 function 0 NVIDIA MCP77 LAN rev 0xa2: apic 0 int 5 (irq 
5), address 00:21:85:55:af:d3
 eephy0 at nfe0 phy 1: 88E1116 Gigabit PHY, rev. 1
 ppb1 at pci0 dev 16 function 0 NVIDIA MCP77 PCIE rev 0xa1: apic 0 int 7 (irq 
7)
@@ -149,4 +142,4 @@
 vscsi0 at root
 scsibus2 at vscsi0: 256 targets
 softraid0 at root
-root on wd0a swap on wd0b dump on wd0b
+root on sd0a swap on sd0b dump on sd0b


-f
-- 
go and catch a falling star...



acpi question

2009-09-04 Thread frantisek holop
hi there,

poking around in my bios i have found the following setting:

Power Now!(tm) Technology [Enabled]

the help message says:

Enable/disable the generation of ACPI _PPC, _PSS, and _PCT objects.

if anybody knowledgable reads this, what does this mean
and how would flipping this affect openbsd?  thanks.

-f
-- 
there is only one universal passion: fear.



Re: 4.6-beta acpicpu0 panic

2009-07-31 Thread frantisek holop
hmm, on Fri, Jul 31, 2009 at 08:36:12AM -0500, Marco Peereboom said that
 Well that sort of tells me that ahci hasn't caught up with all latest
 chips.  I will look at that acpicpu thing though.

the disk is in legacy ide mode (thru bios) because it's dual booted.
when i tried throwing the switch to ahci the kernel made a salto mortale.
i will try it again and post the result here.

-f
-- 
never say anything more predictive than watch this!



Re: 4.6-beta acpicpu0 panic

2009-07-30 Thread frantisek holop
hmm, on Wed, Jul 29, 2009 at 08:50:14PM -0500, Marco Peereboom said that
 did you try disabling acpicpu only?

i have tried this and here is the dmesg:
(it is also accessible under obiit.org/f/dmesg.bsd.sp.acpi)

OpenBSD 4.6-current (GENERIC) #85: Mon Jul 27 19:10:16 MDT 2009
dera...@i386.openbsd.org:/usr/src/sys/arch/i386/compile/GENERIC
cpu0: AMD Turion(tm) X2 Ultra Dual-Core Mobile ZM-80 (AuthenticAMD 686-class, 
1024KB L2 cache) 2.11 GHz
cpu0: 
FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,CX16
real mem  = 3217108992 (3068MB)
avail mem = 311880 (2972MB)
User Kernel Config
UKC disable acpicpu
471 acpicpu* disabled
UKC quit
Continuing...
mainbus0 at root
bios0 at mainbus0: AT/286+ BIOS, date 02/08/08, SMBIOS rev. 2.4 @ 0xbfb51018 
(53 entries)
bios0: vendor American Megatrends Inc. version E1652NMS VER.106 date 
12/26/2008
bios0: Micro-Star International GX-630
acpi0 at bios0: rev 2
acpi0: tables DSDT FACP APIC SSDT MCFG SLIC
acpi0: wakeup devices PS2K(S4) PS2M(S4) NSMB(S4) USB0(S4) USB2(S3) USB1(S4) 
USB4(S3) NMAC(S5) HDAC(S4) POP2(S4) BR12(S4) BR13(S4) BR14(S4) BR16(S4) 
SLPB(S4) PWRB(S4)
acpitimer0 at acpi0: 3579545 Hz, 24 bits
acpimadt0 at acpi0 addr 0xfee0: PC-AT compat
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: apic clock running at 200MHz
cpu at mainbus0: not configured
ioapic0 at mainbus0: apid 0 pa 0xfec0, version 11, 24 pins
acpiprt0 at acpi0: bus 0 (PCI0)
acpiprt1 at acpi0: bus 3 (BR12)
acpiprt2 at acpi0: bus 4 (BR13)
acpiprt3 at acpi0: bus 5 (BR14)
acpiprt4 at acpi0: bus 8 (BR16)
acpiec0 at acpi0
acpicpu at acpi0 not configured
acpitz0 at acpi0: critical temperature 100 degC
acpiac0 at acpi0: AC unit online
acpibat0 at acpi0: BAT1 model MS-1221
 serial 
 type LION
 oem MSI Corp.

acpibtn0 at acpi0: LID0
acpibtn1 at acpi0: SLPB
acpibtn2 at acpi0: PWRB
acpivideo0 at acpi0: VGA_
acpivout0 at acpivideo0: CRT_
acpivout1 at acpivideo0: LCD_
acpivout2 at acpivideo0: HDMI
bios0: ROM list: 0xc/0xe200 0xce800/0x1800
pci0 at mainbus0 bus 0: configuration mode 1 (bios)
NVIDIA MCP77 Memory rev 0xa2 at pci0 dev 0 function 0 not configured
pcib0 at pci0 dev 1 function 0 NVIDIA MCP77 ISA rev 0xa2
nviic0 at pci0 dev 1 function 1 NVIDIA MCP77 SMBus rev 0xa1
iic0 at nviic0
iic1 at nviic0
spdmem0 at iic1 addr 0x50: 2GB DDR2 SDRAM non-parity PC2-6400CL5 SO-DIMM
spdmem1 at iic1 addr 0x51: 2GB DDR2 SDRAM non-parity PC2-6400CL5 SO-DIMM
NVIDIA MCP77 Co-processor rev 0xa2 at pci0 dev 1 function 3 not configured
NVIDIA MCP77 Memory rev 0xa1 at pci0 dev 1 function 4 not configured
ohci0 at pci0 dev 2 function 0 NVIDIA MCP77 USB rev 0xa1: apic 0 int 7 (irq 
7), version 1.0, legacy support
ehci0 at pci0 dev 2 function 1 NVIDIA MCP77 USB rev 0xa1: apic 0 int 11 (irq 
11)
usb0 at ehci0: USB revision 2.0
uhub0 at usb0 NVIDIA EHCI root hub rev 2.00/1.00 addr 1
ohci1 at pci0 dev 4 function 0 NVIDIA MCP77 USB rev 0xa1: apic 0 int 5 (irq 
5), version 1.0, legacy support
ehci1 at pci0 dev 4 function 1 NVIDIA MCP77 USB rev 0xa1: apic 0 int 7 (irq 7)
usb1 at ehci1: USB revision 2.0
uhub1 at usb1 NVIDIA EHCI root hub rev 2.00/1.00 addr 1
pciide0 at pci0 dev 6 function 0 NVIDIA MCP77 IDE rev 0xa1: DMA, channel 0 
configured to compatibility, channel 1 configured to compatibility
pciide0: channel 0 ignored (disabled)
pciide0: channel 1 ignored (disabled)
azalia0 at pci0 dev 7 function 0 NVIDIA MCP77 HD Audio rev 0xa1: apic 0 int 
11 (irq 11)
azalia0: codecs: Realtek ALC888, Motorola/0x3055, NVIDIA/0x0006, using Realtek 
ALC888
audio0 at azalia0
ppb0 at pci0 dev 8 function 0 NVIDIA MCP77 PCI rev 0xa1
pci1 at ppb0 bus 1
pciide1 at pci0 dev 9 function 0 NVIDIA MCP77 AHCI rev 0xa2: DMA 
(unsupported), channel 0 wired to native-PCI, channel 1 wired to native-PCI
pciide1: using apic 0 int 10 (irq 10) for native-PCI interrupt
wd0 at pciide1 channel 0 drive 0: FUJITSU MHZ2320BH G2
wd0: 16-sector PIO, LBA48, 305245MB, 625142448 sectors
atapiscsi0 at pciide1 channel 0 drive 1
scsibus0 at atapiscsi0: 2 targets
cd0 at scsibus0 targ 0 lun 0: Optiarc, DVD RW AD-7560S, SX01 ATAPI 5/cdrom 
removable
pciide1: channel 1 ignored (not responding; disabled or no drives?)
nfe0 at pci0 dev 10 function 0 NVIDIA MCP77 LAN rev 0xa2: apic 0 int 5 (irq 
5), address 00:21:85:55:af:d3
eephy0 at nfe0 phy 1: 88E1116 Gigabit PHY, rev. 1
ppb1 at pci0 dev 16 function 0 NVIDIA MCP77 PCIE rev 0xa1: apic 0 int 7 (irq 
7)
pci2 at ppb1 bus 2
vga1 at pci2 dev 0 function 0 vendor NVIDIA, unknown product 0x0649 rev 0xa1
wsdisplay0 at vga1 mux 1: console (80x25, vt100 emulation)
wsdisplay0: screen 1-5 added (80x25, vt100 emulation)
ppb2 at pci0 dev 18 function 0 NVIDIA MCP77 PCIE rev 0xa1: apic 0 int 11 (irq 
11)
pci3 at ppb2 bus 3
ral0 at pci3 dev 0 function 0 Ralink RT2790 rev 0x00: apic 0 int 11 (irq 11), 
address 00:21:85:b3:c4:ec
ral0: MAC/BBP RT2872 (rev 0x0200), RF RT2720 (MIMO 1T2R)
ppb3 at pci0 dev 19 function 0 NVIDIA MCP77 PCI rev 0xa1: apic 0 int 5 (irq 5)
pci4 at ppb3 bus 4
ppb4 

Re: 4.6-beta acpicpu0 panic

2009-07-30 Thread frantisek holop
hmm, on Thu, Jul 30, 2009 at 11:05:14AM -0500, Marco Peereboom said that
 But is that an interrupt issue or does the disk simply suck?

the interrupt issues i reported about this machine are gone (atm).
interrupts in top showed normal level as far as i can tell.
this disk is of course the highest udma breed (actually it is
ahci, but last time i checked it wasn't found by the kernel)
but if it's doing PIO, doing anything that touches the disk
makes everything go slow-mo.

just send me any commands you want me to execute and collect
the output...

-f
-- 
if people listened to themselves more often, they would shut up.



4.6-beta installer disklabeling bug(?)

2009-07-02 Thread frantisek holop
hi there,

i gave 4.6-beta a shot tonight and this is the first mail
to report some findings.

this is the fdisk output on the notebook.  please note
that there are 3 NTFS partitions and an openbsd one.

Disk: wd0   geometry: 38913/255/63 [625142448 Sectors]
Offset: 0   Signature: 0xAA55
Starting Ending LBA Info:
 #: id  C   H   S -  C   H   S [   start:size ]
---
*0: 07  0   1   1 -   8354 254  63 [  63:   134223012 ] NTFS
 1: 07   8355   0   1 -  25063 254  63 [   134223075:   268430085 ] NTFS
 2: A6  25064   0   1 -  29240 254  63 [   402653160:67103505 ] OpenBSD 
 3: 07  29241   0   1 -  38912 254  63 [   469756665:   155380680 ] NTFS

when i am presented with the (a)utolayout the 3 NTFS partitions
show up (correctly) as i, j, and k amongst the miriad openbsd
partitions.

however if i choose (e)dit layout i am presented with the following
disklabel output:

#size   offset  fstype [fsize bsize  cpg]
  a: 67103505402653160  4.2BSD   2048 163841 
  c:6251424480  unused   
  i:134223012   63NTFS   
  j:268430085134223075NTFS   
 
'k' is gone.
if indeed the installer removed it before having me the interactive
prompt, i guess the new disklabel would really not contain 'k' if
i saved it (i didn't).  instead i edited the autolayout and made
my own layout.

-f

OpenBSD 4.6 (RAMDISK_CD) #38: Thu Jul  2 00:16:47 MDT 2009
dera...@i386.openbsd.org:/usr/src/sys/arch/i386/compile/RAMDISK_CD
cpu0: AMD Turion(tm) X2 Ultra Dual-Core Mobile ZM-80 (AuthenticAMD 686-class, 
1024KB L2 cache) 2.11 GHz
cpu0: 
FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,CX16
real mem  = 3217108992 (3068MB)
avail mem = 3118411776 (2973MB)
mainbus0 at root
bios0 at mainbus0: AT/286+ BIOS, date 02/08/08, SMBIOS rev. 2.4 @ 0xbfb51018 
(53 entries)
bios0: vendor American Megatrends Inc. version E1652NMS VER.106 date 
12/26/2008
bios0: Micro-Star International GX-630
acpi0 at bios0: rev 2
acpi0: tables DSDT FACP APIC SSDT MCFG SLIC
acpimadt0 at acpi0 addr 0xfee0: PC-AT compat
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: apic clock running at 200MHz
cpu at mainbus0: not configured
ioapic0 at mainbus0: apid 0 pa 0xfec0, version 11, 24 pins
acpiprt0 at acpi0: bus 0 (PCI0)
acpiprt1 at acpi0: bus 3 (BR12)
acpiprt2 at acpi0: bus 4 (BR13)
acpiprt3 at acpi0: bus 5 (BR14)
acpiprt4 at acpi0: bus 8 (BR16)
bios0: ROM list: 0xc/0xe200 0xce800/0x1800
pci0 at mainbus0 bus 0: configuration mode 1 (bios)
NVIDIA MCP77 Memory rev 0xa2 at pci0 dev 0 function 0 not configured
pcib0 at pci0 dev 1 function 0 vendor NVIDIA, unknown product 0x075e rev 0xa2
NVIDIA MCP77 SMBus rev 0xa1 at pci0 dev 1 function 1 not configured
NVIDIA MCP77 Co-processor rev 0xa2 at pci0 dev 1 function 3 not configured
NVIDIA MCP77 Memory rev 0xa1 at pci0 dev 1 function 4 not configured
ohci0 at pci0 dev 2 function 0 NVIDIA MCP77 USB rev 0xa1: apic 0 int 7 (irq 
7), version 1.0, legacy support
ehci0 at pci0 dev 2 function 1 NVIDIA MCP77 USB rev 0xa1: apic 0 int 11 (irq 
11)
usb0 at ehci0: USB revision 2.0
uhub0 at usb0 NVIDIA EHCI root hub rev 2.00/1.00 addr 1
ohci1 at pci0 dev 4 function 0 NVIDIA MCP77 USB rev 0xa1: apic 0 int 5 (irq 
5), version 1.0, legacy support
ehci1 at pci0 dev 4 function 1 NVIDIA MCP77 USB rev 0xa1: apic 0 int 7 (irq 7)
usb1 at ehci1: USB revision 2.0
uhub1 at usb1 NVIDIA EHCI root hub rev 2.00/1.00 addr 1
pciide0 at pci0 dev 6 function 0 NVIDIA MCP77 IDE rev 0xa1: DMA, channel 0 
configured to compatibility, channel 1 configured to compatibility
pciide0: channel 0 ignored (disabled)
pciide0: channel 1 ignored (disabled)
NVIDIA MCP77 HD Audio rev 0xa1 at pci0 dev 7 function 0 not configured
ppb0 at pci0 dev 8 function 0 NVIDIA MCP77 PCI rev 0xa1
pci1 at ppb0 bus 1
pciide1 at pci0 dev 9 function 0 NVIDIA MCP77 AHCI rev 0xa2: DMA 
(unsupported), channel 0 wired to native-PCI, channel 1 wired to native-PCI
pciide1: using apic 0 int 10 (irq 10) for native-PCI interrupt
wd0 at pciide1 channel 0 drive 0: FUJITSU MHZ2320BH G2
wd0: 16-sector PIO, LBA48, 305245MB, 625142448 sectors
atapiscsi0 at pciide1 channel 0 drive 1
scsibus0 at atapiscsi0: 2 targets
cd0 at scsibus0 targ 0 lun 0: Optiarc, DVD RW AD-7560S, SX01 ATAPI 5/cdrom 
removable
pciide1: channel 1 ignored (not responding; disabled or no drives?)
nfe0 at pci0 dev 10 function 0 NVIDIA MCP77 LAN rev 0xa2: apic 0 int 5 (irq 
5), address 00:21:85:55:af:d3
eephy0 at nfe0 phy 1: 88E1116 Gigabit PHY, rev. 1
ppb1 at pci0 dev 16 function 0 NVIDIA MCP77 PCIE rev 0xa1: apic 0 int 7 (irq 
7)
pci2 at ppb1 bus 2
vga1 at pci2 dev 0 function 0 vendor NVIDIA, unknown product 0x0649 rev 0xa1
wsdisplay0 at vga1 mux 1: console