Re: Evergrowing source tracking table

2017-05-05 Thread Remi Barbier
Thanks for the quick confirmation.
PR closed.

On 5 May 2017 at 17:55, Mike Belopuhov  wrote:
> On Fri, May 05, 2017 at 16:21 +0200, Remi Barbier wrote:
>> >Synopsis:  PF: Evergrowing source tracking table.
>> >Category:  PF
>> >Environment:
>> System  : OpenBSD 6.1
>> Details : OpenBSD 6.1-current (GENERIC.MP) #50: Thu May  4
>> 11:52:48 MDT 2017
>>
>> dera...@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP
>>
>> Architecture: OpenBSD.amd64
>> Machine : amd64
>> >Description:
>> > removed. Both current and 6.1 are impacted.>
>> >How-To-Repeature:
>> > As shown by pfctl -vsS and pfctl -vsi the expired entries are not
>> removed. pfctl -F Sources won't help.
>>
>> It seems that in the move from pf.c rev 1.1018 to 1.1019, calling
>> pf_remove_src_node() was omitted:
>>
>> RCS file: /cvs/src/sys/net/pf.c,v
>> retrieving revision 1.1018
>> retrieving revision 1.1019
>> diff -u -r1.1018 -r1.1019
>> --- src/sys/net/pf.c2017/03/09 05:47:28 1.1018
>> +++ src/sys/net/pf.c2017/03/17 17:19:16 1.1019
>> @@ -1,4 +1,4 @@
>> -/* $OpenBSD: pf.c,v 1.1018 2017/03/09 05:47:28 claudio Exp $ */
>> +/* $OpenBSD: pf.c,v 1.1019 2017/03/17 17:19:16 mpi Exp $ */
>>
>>  /*
>>   * Copyright (c) 2001 Daniel Hartmeier
>>
>>
>> @@ -1235,20 +1241,26 @@
>>  }
>>
>>  void
>> -pf_purge_expired_src_nodes(void)
>> +pf_purge_expired_src_nodes(int waslocked)
>>  {
>> struct pf_src_node  *cur, *next;
>> +   int  locked = waslocked;
>>
>> -   NET_ASSERT_LOCKED();
>> -
>> for (cur = RB_MIN(pf_src_tree, _src_tracking); cur; cur = next) 
>> {
>> next = RB_NEXT(pf_src_tree, _src_tracking, cur);
>>
>> if (cur->states == 0 && cur->expire <= time_uptime) {
>> -   next = RB_NEXT(pf_src_tree, _src_tracking, cur);
>> -   pf_remove_src_node(cur);
>> +   if (! locked) {
>> +   rw_enter_write(_consistency_lock);
>> +   next = RB_NEXT(pf_src_tree,
>> +   _src_tracking, cur);
>> +   locked = 1;
>> +   }
>> }
>> }
>> +
>> +   if (locked && !waslocked)
>> +   rw_exit_write(_consistency_lock);
>>  }
>> >
>
> Thanks for the report.  You're absolutely right.
>
> diff --git sys/net/pf.c sys/net/pf.c
> index 02af280c9ec..2af0c2da6c6 100644
> --- sys/net/pf.c
> +++ sys/net/pf.c
> @@ -1254,10 +1254,11 @@ pf_purge_expired_src_nodes(int waslocked)
> rw_enter_write(_consistency_lock);
> next = RB_NEXT(pf_src_tree,
> _src_tracking, cur);
> locked = 1;
> }
> +   pf_remove_src_node(cur);
> }
> }
>
> if (locked && !waslocked)
> rw_exit_write(_consistency_lock);



Re: Evergrowing source tracking table

2017-05-05 Thread Mike Belopuhov
On Fri, May 05, 2017 at 16:21 +0200, Remi Barbier wrote:
> >Synopsis:  PF: Evergrowing source tracking table.
> >Category:  PF
> >Environment:
> System  : OpenBSD 6.1
> Details : OpenBSD 6.1-current (GENERIC.MP) #50: Thu May  4
> 11:52:48 MDT 2017
> 
> dera...@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP
> 
> Architecture: OpenBSD.amd64
> Machine : amd64
> >Description:
>  removed. Both current and 6.1 are impacted.>
> >How-To-Repeature:
>  As shown by pfctl -vsS and pfctl -vsi the expired entries are not
> removed. pfctl -F Sources won't help.
> 
> It seems that in the move from pf.c rev 1.1018 to 1.1019, calling
> pf_remove_src_node() was omitted:
> 
> RCS file: /cvs/src/sys/net/pf.c,v
> retrieving revision 1.1018
> retrieving revision 1.1019
> diff -u -r1.1018 -r1.1019
> --- src/sys/net/pf.c2017/03/09 05:47:28 1.1018
> +++ src/sys/net/pf.c2017/03/17 17:19:16 1.1019
> @@ -1,4 +1,4 @@
> -/* $OpenBSD: pf.c,v 1.1018 2017/03/09 05:47:28 claudio Exp $ */
> +/* $OpenBSD: pf.c,v 1.1019 2017/03/17 17:19:16 mpi Exp $ */
> 
>  /*
>   * Copyright (c) 2001 Daniel Hartmeier
> 
> 
> @@ -1235,20 +1241,26 @@
>  }
> 
>  void
> -pf_purge_expired_src_nodes(void)
> +pf_purge_expired_src_nodes(int waslocked)
>  {
> struct pf_src_node  *cur, *next;
> +   int  locked = waslocked;
> 
> -   NET_ASSERT_LOCKED();
> -
> for (cur = RB_MIN(pf_src_tree, _src_tracking); cur; cur = next) {
> next = RB_NEXT(pf_src_tree, _src_tracking, cur);
> 
> if (cur->states == 0 && cur->expire <= time_uptime) {
> -   next = RB_NEXT(pf_src_tree, _src_tracking, cur);
> -   pf_remove_src_node(cur);
> +   if (! locked) {
> +   rw_enter_write(_consistency_lock);
> +   next = RB_NEXT(pf_src_tree,
> +   _src_tracking, cur);
> +   locked = 1;
> +   }
> }
> }
> +
> +   if (locked && !waslocked)
> +   rw_exit_write(_consistency_lock);
>  }
> >

Thanks for the report.  You're absolutely right.

diff --git sys/net/pf.c sys/net/pf.c
index 02af280c9ec..2af0c2da6c6 100644
--- sys/net/pf.c
+++ sys/net/pf.c
@@ -1254,10 +1254,11 @@ pf_purge_expired_src_nodes(int waslocked)
rw_enter_write(_consistency_lock);
next = RB_NEXT(pf_src_tree,
_src_tracking, cur);
locked = 1;
}
+   pf_remove_src_node(cur);
}
}
 
if (locked && !waslocked)
rw_exit_write(_consistency_lock);



www: Dead link on macppc.html

2017-05-05 Thread Scott Cheloha
Hey,

The macppc platform page links to an explanation of the differences
between the OldWorld and NewWorld ROMs:

http://developer.apple.com/technotes/tn/tn1167.html

but that now redirects to the Apple developer API index.

The latest Wayback archive of the intended page is here:


https://web-beta.archive.org/web/2004104718/http://developer.apple.com/technotes/tn/tn1167.html

All archives after that date snagged the aforementioned redirect
instead.

--
Scott Cheloha



Evergrowing source tracking table

2017-05-05 Thread Remi Barbier
>Synopsis:  PF: Evergrowing source tracking table.
>Category:  PF
>Environment:
System  : OpenBSD 6.1
Details : OpenBSD 6.1-current (GENERIC.MP) #50: Thu May  4
11:52:48 MDT 2017

dera...@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP

Architecture: OpenBSD.amd64
Machine : amd64
>Description:

>How-To-Repeature:
states == 0 && cur->expire <= time_uptime) {
-   next = RB_NEXT(pf_src_tree, _src_tracking, cur);
-   pf_remove_src_node(cur);
+   if (! locked) {
+   rw_enter_write(_consistency_lock);
+   next = RB_NEXT(pf_src_tree,
+   _src_tracking, cur);
+   locked = 1;
+   }
}
}
+
+   if (locked && !waslocked)
+   rw_exit_write(_consistency_lock);
 }
>
>Fix:



dmesg:
OpenBSD 6.1-current (GENERIC.MP) #50: Thu May  4 11:52:48 MDT 2017
dera...@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP
real mem = 16033693696 (15290MB)
avail mem = 15541968896 (14821MB)
mpath0 at root
scsibus0 at mpath0: 256 targets
mainbus0 at root
bios0 at mainbus0: SMBIOS rev. 2.7 @ 0xec470 (75 entries)
bios0: vendor Intel Corp. version "KBQ7710H.86A.0058.2015.0729.1616"
date 07/29/2015
bios0: Intel Corporation DQ77KB
acpi0 at bios0: rev 2
acpi0: sleep states S0 S3 S4 S5
acpi0: tables DSDT FACP APIC FPDT TCPA MCFG HPET SSDT SSDT SSDT DMAR ASF! BGRT
acpi0: wakeup devices P0P1(S4) USB1(S3) USB2(S3) USB3(S3) USB4(S3)
USB5(S3) USB6(S3) USB7(S3) PXSX(S4) RP01(S4) PXSX(S4) RP02(S4)
PXSX(S4) RP03(S4) PXSX(S4) RP04(S4) [...]
acpitimer0 at acpi0: 3579545 Hz, 24 bits
acpimadt0 at acpi0 addr 0xfee0: PC-AT compat
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: Intel(R) Core(TM) i7-3770S CPU @ 3.10GHz, 3093.47 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,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,POPCNT,DEADLINE,AES,XSAVE,AVX,F16C,RDRAND,NXE,RDTSCP,LONG,LAHF,PERF,ITSC,FSGSBASE,SMEP,ERMS,SENSOR,ARAT
cpu0: 256KB 64b/line 8-way L2 cache
cpu0: TSC frequency 3093474280 Hz
cpu0: smt 0, core 0, package 0
mtrr: Pentium Pro MTRR support, 10 var ranges, 88 fixed ranges
cpu0: apic clock running at 99MHz
cpu0: mwait min=64, max=64, C-substates=0.2.1.1, IBE
cpu1 at mainbus0: apid 2 (application processor)
cpu1: Intel(R) Core(TM) i7-3770S CPU @ 3.10GHz, 3092.99 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,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,POPCNT,DEADLINE,AES,XSAVE,AVX,F16C,RDRAND,NXE,RDTSCP,LONG,LAHF,PERF,ITSC,FSGSBASE,SMEP,ERMS,SENSOR,ARAT
cpu1: 256KB 64b/line 8-way L2 cache
cpu1: smt 0, core 1, package 0
cpu2 at mainbus0: apid 4 (application processor)
cpu2: Intel(R) Core(TM) i7-3770S CPU @ 3.10GHz, 3092.99 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,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,POPCNT,DEADLINE,AES,XSAVE,AVX,F16C,RDRAND,NXE,RDTSCP,LONG,LAHF,PERF,ITSC,FSGSBASE,SMEP,ERMS,SENSOR,ARAT
cpu2: 256KB 64b/line 8-way L2 cache
cpu2: smt 0, core 2, package 0
cpu3 at mainbus0: apid 6 (application processor)
cpu3: Intel(R) Core(TM) i7-3770S CPU @ 3.10GHz, 3092.99 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,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,POPCNT,DEADLINE,AES,XSAVE,AVX,F16C,RDRAND,NXE,RDTSCP,LONG,LAHF,PERF,ITSC,FSGSBASE,SMEP,ERMS,SENSOR,ARAT
cpu3: 256KB 64b/line 8-way L2 cache
cpu3: smt 0, core 3, package 0
cpu4 at mainbus0: apid 1 (application processor)
cpu4: Intel(R) Core(TM) i7-3770S CPU @ 3.10GHz, 3092.99 MHz
cpu4: 
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,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,POPCNT,DEADLINE,AES,XSAVE,AVX,F16C,RDRAND,NXE,RDTSCP,LONG,LAHF,PERF,ITSC,FSGSBASE,SMEP,ERMS,SENSOR,ARAT
cpu4: 256KB 64b/line 8-way L2 cache
cpu4: smt 1, core 0, package 0
cpu5 at mainbus0: apid 3 (application processor)
cpu5: Intel(R) Core(TM) i7-3770S CPU @ 3.10GHz, 3092.99 MHz
cpu5: 
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,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,POPCNT,DEADLINE,AES,XSAVE,AVX,F16C,RDRAND,NXE,RDTSCP,LONG,LAHF,PERF,ITSC,FSGSBASE,SMEP,ERMS,SENSOR,ARAT
cpu5: 256KB 64b/line 8-way L2 cache
cpu5: 

Re: config in 6.1 reports /dev/mem: Operation not permitted

2017-05-05 Thread John DiMarco
In message <20170505091608.gd17...@sci.irofti.net>you write:
>>  0:6:0: Cirrus Logic CS4610 SoundFusion
>>  0x: Vendor ID: 1013 Product ID: 6001
>>  0x0004: Command: 0106 Status: 0200
>>  0x0008: Class: 04 Subclass: 01 Interface: 00 Revision: 01
>
>This says you do have clcs(4) hardware on your laptop. What is the exact
>error you are seeing when booting the original kernel?

Hmm, yes, you're quite right, it does look like the onboard sound
chip is a CS4610.  http://www.lenovo.com/psref/pdf/twbook.pdf (p48) 
I never particularly cared much about the sound card (though there's no
harm in getting it to work correctly), the main reason I still use this
ancient laptop is its superb keyboard.

Anyway, I re-enabled clcs; dmesg appended below

Thanks,

John
--
John DiMarco    http://www.cs.toronto.edu/~jdd
IT Director, Department of Computer Science, University of Toronto  
Office: SF3302  1-416-978-5300  Fx:1-416-946-5464  Skype:jddimarco


OpenBSD 6.1 (GENERIC) #1: Wed May  3 01:51:12 CEST 2017
rob...@syspatch-61-i386.openbsd.org:/usr/src/sys/arch/i386/compile/GENERIC
cpu0: Intel Celeron ("GenuineIntel" 686-class, 256KB L2 cache) 398 MHz
cpu0: 
FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,SEP,MTRR,PGE,MCA,CMOV,PSE36,MMX,FXSR,PERF
real mem  = 301285376 (287MB)
avail mem = 282808320 (269MB)
mpath0 at root
scsibus0 at mpath0: 256 targets
mainbus0 at root
bios0 at mainbus0: date 11/20/99, BIOS32 rev. 0 @ 0xfd820, SMBIOS rev. 2.2 @ 
0xf6cf0 (55 entries)
bios0: vendor IBM version "INET30WW" date 11/20/1999
bios0: IBM 26454BU
acpi at bios0 function 0x0 not configured
apm0 at bios0: Power Management spec V1.2
pcibios0 at bios0: rev 2.1 @ 0xfd880/0x800
pcibios0: PCI IRQ Routing Table rev 1.0 @ 0xf9e20/112 (5 entries)
pcibios0: PCI Exclusive IRQs: 11
pcibios0: PCI Interrupt Router at 000:07:0 ("Intel 82371AB PIIX4 ISA" rev 0x00)
pcibios0: PCI bus #5 is the last bus
bios0: ROM list: 0xc/0xc000
cpu0 at mainbus0: (uniprocessor)
mtrr: Pentium Pro MTRR support, 8 var ranges, 88 fixed ranges
pci0 at mainbus0 bus 0: configuration mode 1 (bios)
pchb0 at pci0 dev 0 function 0 "Intel 82443BX AGP" rev 0x03
intelagp0 at pchb0
agp0 at intelagp0: aperture at 0x4000, size 0x400
ppb0 at pci0 dev 1 function 0 "Intel 82443BX AGP" rev 0x03
pci1 at ppb0 bus 1
vga1 at pci1 dev 0 function 0 "Neomagic Magicgraph NM2200" rev 0x20
wsdisplay0 at vga1 mux 1: console (80x25, vt100 emulation)
wsdisplay0: screen 1-5 added (80x25, vt100 emulation)
cbb0 at pci0 dev 2 function 0 "TI PCI1251 CardBus" rev 0x00: irq 11
cbb1 at pci0 dev 2 function 1 "TI PCI1251 CardBus" rev 0x00: irq 11
clcs0 at pci0 dev 6 function 0 "Cirrus Logic CS4610 SoundFusion" rev 0x01: irq 
11
reset_codec: AC97 inputs slot ready timeout
clcs0: AC97 write fail (DCV!=0) for add=0x26 data=0x
clcs0: AC97 write fail (DCV!=0) for add=0x00 data=0x
clcs0: AC97 write fail (DCV!=0) for add=0x00 data=0x
clcs0: AC97 write fail (DCV!=0) for add=0x00 data=0x
clcs0: AC97 write fail (DCV!=0) for add=0x00 data=0x
clcs0: AC97 write fail (DCV!=0) for add=0x02 data=0x8000
clcs0: AC97 write fail (DCV!=0) for add=0x06 data=0x8000
clcs0: AC97 write fail (DCV!=0) for add=0x20 data=0x
clcs0: AC97 write fail (DCV!=0) for add=0x04 data=0x8000
clcs0: AC97 write fail (DCV!=0) for add=0x38 data=0x8080
clcs0: AC97 write fail (DCV!=0) for add=0x36 data=0x8080
clcs0: AC97 write fail (DCV!=0) for add=0x36 data=0x8080
clcs0: AC97 write fail (DCV!=0) for add=0x36 data=0x8080
clcs0: AC97 write fail (DCV!=0) for add=0x36 data=0x8080
clcs0: AC97 write fail (DCV!=0) for add=0x08 data=0x0f0f
clcs0: AC97 write fail (DCV!=0) for add=0x0a data=0x
clcs0: AC97 write fail (DCV!=0) for add=0x0c data=0x8008
clcs0: AC97 write fail (DCV!=0) for add=0x0e data=0x8008
clcs0: AC97 write fail (DCV!=0) for add=0x0e data=0x8008
clcs0: AC97 write fail (DCV!=0) for add=0x20 data=0x
clcs0: AC97 write fail (DCV!=0) for add=0x10 data=0x8808
clcs0: AC97 write fail (DCV!=0) for add=0x12 data=0x8808
clcs0: AC97 write fail (DCV!=0) for add=0x14 data=0x8808
clcs0: AC97 write fail (DCV!=0) for add=0x16 data=0x8808
clcs0: AC97 write fail (DCV!=0) for add=0x18 data=0x8808
clcs0: AC97 write fail (DCV!=0) for add=0x1a data=0x
clcs0: AC97 write fail (DCV!=0) for add=0x1c data=0x8000
clcs0: AC97 write fail (DCV!=0) for add=0x1e data=0x8000
clcs0: AC97 write fail (DCV!=0) for add=0x20 data=0x
clcs0: AC97 write fail (DCV!=0) for add=0x20 data=0x
clcs0: AC97 write fail (DCV!=0) for add=0x22 data=0x
clcs0: AC97 write fail (DCV!=0) for add=0x22 data=0x
clcs0: AC97 write fail (DCV!=0) for add=0x26 data=0x
clcs0: AC97 write fail (DCV!=0) for add=0x2a data=0x
clcs0: AC97 read prob. (DCV!=0) for add=0x7c
clcs0: AC97 read prob. (DCV!=0) for add=0x7e
clcs0: AC97 read prob. (DCV!=0) for add=0x00
ac97: codec id not read
clcs0: AC97 read prob. (DCV!=0) for add=0x28
clcs0: AC97 read prob. (DCV!=0) for add=0x02
clcs0: AC97 write fail (DCV!=0) for add=0x02 data=0x

Invalid syntax error from syntax_is_time() on ldapd(8) when adding entries

2017-05-05 Thread Seiya Kawashima
>Synopsis:  Invalid syntax error from syntax_is_time() on ldapd(8) when 
>adding entries
>Category:  system
>Environment:
System  : OpenBSD 6.1
Details : OpenBSD 6.1-current (GENERIC.MP) #50: Thu May  4 11:52:48 
MDT 2017
 
dera...@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP

Architecture: OpenBSD.amd64
Machine : amd64
>Description:
Thank you for the great work on ldapd(8).

ldapd(8) had been working great until I moved to OpenBSD 6.1-current 
(GENERIC.MP) #50.
The entire dmesg is attached at the end of this report. If this report 
is not relevant,
please discard it. The relevant parts are syntax_is_gentime(), 
syntax_is_utctime and
syntax_is_time() on syntax.c. I still wonder why it worked without the 
fix shown below and
now it doesn't work without any modification.

When adding entries to ldapd(8), a "createTimestamp" attribute is added 
as a part of
the operational attributes within ber_add_string() on modify.c. The 
"createTimestamp"
is created by ldap_strftime() via ldap_now() on attributes.c. 
ldap_strftime() calls
strftime(3) as follows:

strftime(tmbuf, sizeof(tmbuf), "%Y%m%d%H%M%SZ", gmt);

ldap_now() returns a Generalized Time character string as follows:

20170504184415Z


When this "createTimestamp" attribute is created, it's validated by the 
corresponding
validation function. This function seems to cause the Invalid syntax 
error and ldapd(8)
aborts the addition at the time.


The "createTimestamp" attribute is set to have syntax_is_gentime() as 
the validation
function on syntax.c like below.

static struct syntax syntaxes[] = {

...
{ "1.3.6.1.4.1.1466.115.121.1.24", "Generalized Time", 
syntax_is_gentime }
...

};

syntax_is_gentime() is a wrapper function of syntax_is_time() setting 1 
as the third
parameter. Another wrapper function of syntax_is_time() is 
syntax_is_utctime() setting
0 as the third parameter. syntax_is_gentime() intends to be for 
Generalized Time and
syntax_is_utctime intends to be for UTC Time. They are on syntax.c.

static int
syntax_is_gentime(struct schema *schema, char *value, size_t 
len)
{
return syntax_is_time(schema, value, len, 1);
}

static int
syntax_is_utctime(struct schema *schema, char *value, size_t 
len)
{
return syntax_is_time(schema, value, len, 0);
}

When the Generalized Time character string is validated by 
syntax_is_time() on syntax.c,
Invalid syntax error is returned. The error appears on the client side 
like

$ ldapadd -vv -H ldaps://192.168.2.5 -x -D 
"cn=admin,dc=example,dc=com" -w secret \
-f ./ldapd-invalid-syntax.ldif
ldap_initialize( ldaps://192.168.2.5:636/??base )
add dc:
example
add description:
My wonderful company as much text as you want to place 
in here.
add objectClass:
dcObject
organization
add o:
Example, Inc.
adding new entry "dc=example,dc=com"
ldap_add: Invalid syntax (21)

The error appears on the ldapd(8) side like

$sudo ldapd -dvvv
...
btree_txn_begin:686: begin transaction on btree 0x42dabec5a00, 
root page 4294967295
btree_txn_begin:666: taking write lock on txn 0x42cf176f1a0
btree_ref:1166: ref is now 2 on btree 0x42dabec5b00
btree_read_meta:1011: btree_read_meta: size = 16384
btree_txn_begin:686: begin transaction on btree 0x42dabec5b00, 
root page 4294967295
May  4 14:58:31.659 [34392] createTimestamp: invalid syntax
May  4 14:58:31.659 [34392] syntax = Generalized Time
May  4 14:58:31.659 [34392] value: [20170504195831Z]
btree_txn_abort:701: abort transaction on btree 0x42dabec5a00, 
root page 4294967295
btree_txn_abort:714: releasing write lock on txn 0x42d6e68f100
btree_close:1184: ref is now 1 on btree 0x42dabec5a00
btree_txn_abort:701: abort transaction on btree 0x42dabec5b00, 
root page 4294967295
btree_txn_abort:714: releasing write lock on txn 0x42cf176f1a0
btree_close:1184: ref is now 1 on btree 0x42dabec5b00
May  4 14:58:31.659 [34392] sending response 9 with result 21
...


The client that I 

Re: config in 6.1 reports /dev/mem: Operation not permitted

2017-05-05 Thread Paul Irofti
>  0:6:0: Cirrus Logic CS4610 SoundFusion
>   0x: Vendor ID: 1013 Product ID: 6001
>   0x0004: Command: 0106 Status: 0200
>   0x0008: Class: 04 Subclass: 01 Interface: 00 Revision: 01

This says you do have clcs(4) hardware on your laptop. What is the exact
error you are seeing when booting the original kernel?

>   0x000c: BIST: 00 Header Type: 00 Latency Timer: 20 Cache Line Size: 00
>   0x0010: BAR mem 32bit addr: 0x5010/0x1000
>   0x0014: BAR mem 32bit addr: 0x5000/0x0010
>   0x0018: BAR empty ()
>   0x001c: BAR empty ()
>   0x0020: BAR empty ()
>   0x0024: BAR empty ()
>   0x0028: Cardbus CIS: 
>   0x002c: Subsystem Vendor ID: 1014 Product ID: 1010
>   0x0030: Expansion ROM Base Address: 
>   0x0038: 
>   0x003c: Interrupt Pin: 01 Line: 0b Min Gnt: 04 Max Lat: 18
>   0x: 60011013 02000106 04010001 2000
>   0x0010: 5010 5000  
>   0x0020:    10101014
>   0x0030:    1804010b
>   0x0040:    
>   0x0050:    
>   0x0060:    
>   0x0070:    
>   0x0080:    
>   0x0090:    
>   0x00a0:    
>   0x00b0:    
>   0x00c0:    
>   0x00d0:    
>   0x00e0:    
>   0x00f0: