Re: (beagleboneblack/urtwn) Kernel page fault with the following non-sleepable locks held [ssh on rpi2 comparison]

2016-06-22 Thread Otacílio

Em 21/06/2016 19:45, Keith White escreveu:

On Tue, 21 Jun 2016, Ian Lepore wrote:


On Tue, 2016-06-21 at 08:11 -0300, Otacílio wrote:

Em 21/06/2016 07:33, Keith White escreveu:

In an earlier message Ian said that he thought he knew what the
problem was...


Here the problem occurs  when using wifi. I do not have tested wired
because I don't have a cable here.


[]'s

-Otacilio


The wifi alignment fault should be fixed as of r302064.  Sorry it took
so long.

-- Ian


Many thanks Ian!  Yes, this has fixed the problem.  No more panics
on ssh to rpi-b.

...keith


This fix on beaglebone black also. Thanks a lot!

[]'s

-Otacílio

___
freebsd-current@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"


Re: (beagleboneblack/urtwn) Kernel page fault with the following non-sleepable locks held [ssh on rpi2 comparison]

2016-06-21 Thread Ian Lepore
On Tue, 2016-06-21 at 15:30 -0700, Mark Millard wrote:
> Ian Lepore ian at freebsd.org  wrote on Tue Jun 21 17:55:28 UTC 2016
> :
> 
> > On Tue, 2016-06-21 at 08:11 -0300, Otacílio wrote:
> > > Em 21/06/2016 07:33, Keith White escreveu:
> > > > In an earlier message Ian said that he thought he knew what the
> > > > problem was... 
> > > 
> > > Here the problem occurs  when using wifi. I do not have tested
> > > wired 
> > > because I don't have a cable here.
> > > 
> > > 
> > > []'s
> > > 
> > > -Otacilio
> > 
> > The wifi alignment fault should be fixed as of r302064.  Sorry it
> > took
> > so long.
> > 
> > -- Ian
> > 
> 
> FYI: I've not had any -r301975 problems with WiFi on my rpi2.
> 
> But I cross build for TARGET_ARCH=armv6 with:
> 
> > XCFLAGS+= -march=armv7-a -mcpu=cortex-a7
> > XCXXFLAGS+= -march=armv7-a -mcpu=cortex-a7
> 
> (And similarly for self-hosted.) It may be that the -march and/or 
> -mcpu matter to the code generation and explain my lack of problems.
> 
> The builds also have INVARIANTS and WITNESS off.
> 
> ===
> Mark Millard
> markmi at dsl-only.net

INVARIANTS being on was one of the things required to trigger the
alignment fault.

-- Ian

___
freebsd-current@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"


Re: (beagleboneblack/urtwn) Kernel page fault with the following non-sleepable locks held [ssh on rpi2 comparison]

2016-06-21 Thread Keith White

On Tue, 21 Jun 2016, Ian Lepore wrote:


On Tue, 2016-06-21 at 08:11 -0300, Otacílio wrote:

Em 21/06/2016 07:33, Keith White escreveu:

In an earlier message Ian said that he thought he knew what the
problem was...


Here the problem occurs  when using wifi. I do not have tested wired
because I don't have a cable here.


[]'s

-Otacilio


The wifi alignment fault should be fixed as of r302064.  Sorry it took
so long.

-- Ian


Many thanks Ian!  Yes, this has fixed the problem.  No more panics
on ssh to rpi-b.

...keith
___
freebsd-current@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"


Re: (beagleboneblack/urtwn) Kernel page fault with the following non-sleepable locks held [ssh on rpi2 comparison]

2016-06-21 Thread Ian Lepore
On Tue, 2016-06-21 at 08:11 -0300, Otacílio wrote:
> Em 21/06/2016 07:33, Keith White escreveu:
> > In an earlier message Ian said that he thought he knew what the
> > problem was... 
> 
> Here the problem occurs  when using wifi. I do not have tested wired 
> because I don't have a cable here.
> 
> 
> []'s
> 
> -Otacilio

The wifi alignment fault should be fixed as of r302064.  Sorry it took
so long.

-- Ian

___
freebsd-current@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"


Re: (beagleboneblack/urtwn) Kernel page fault with the following non-sleepable locks held [ssh on rpi2 comparison]

2016-06-21 Thread Mark Millard
[A top-post of a new result: WiFI works fine too. Quotes are from input/output, 
with some redacting. This is the first time I've set up WiFi on FreeBSD.]

WiFI (urtwn0) also works fine for me with ssh on the rpi2 11.0 -r301975 
context. . .

> urtwn0:  on 
> usbus0
> urtwn0: MAC/BB RTL8188CUS, RF 6052 1T1R
> urtwn0: enabling 11n


> # ifconfig
. . .
> wlan0: flags=8843 metric 0 mtu 1500
> ether 
> inet 192.168.0.122 netmask 0xff00 broadcast 192.168.0.255 
> groups: wlan 
> ssid "Millard's AirPort2" channel 11 (2462 MHz 11g ht/20) bssid 
> regdomain FCC country US authmode WPA2/802.11i privacy ON
> deftxkey UNDEF TKIP 3:128-bit txpower 30 bmiss 7 scanvalid 60
> protmode CTS ht20 -ampdutx ampdurx ampdulimit 64k ampdudensity 4 -stbc
> wme roaming MANUAL
> media: IEEE 802.11 Wireless Ethernet MCS mode 11ng
> status: associated
> nd6 options=29


An ssh markmi@192.168.0.122 into the rpi2 from Mac OS X's terminal worked fine:

> Warning: Permanently added '192.168.0.122' (ECDSA) to the list of known hosts.
> Password for markmi@rpi2:
> Last login: Tue Jun 21 01:04:54 2016 from 192.168.0.105
> FreeBSD 11.0-ALPHA4 (RPI2-NODBG) #1 r301975M: Thu Jun 16 18:12:02 PDT 2016
> 
> Welcome to FreeBSD!
> 
> Release Notes, Errata: https://www.FreeBSD.org/releases/
> Security Advisories:   https://www.FreeBSD.org/security/
> FreeBSD Handbook:  https://www.FreeBSD.org/handbook/
> FreeBSD FAQ:   https://www.FreeBSD.org/faq/
> Questions List: https://lists.FreeBSD.org/mailman/listinfo/freebsd-questions/
> FreeBSD Forums:https://forums.FreeBSD.org/
> 
> Documents installed with the system are in the /usr/local/share/doc/freebsd/
> directory, or can be installed later with:  pkg install en-freebsd-doc
> For other languages, replace "en" with a language code like de or fr.
> 
> Show the version of FreeBSD installed:  freebsd-version ; uname -a
> Please include that output and any error messages when posting questions.
> Introduction to manual pages:  man man
> FreeBSD directory layout:  man hier
> 
> Edit /etc/motd to change this login announcement.
> You can look through a file in a nice text-based interface by typing
> 
>   less filename
> $ 

The problem is apparently not general to all armv6 WiFi contexts.

I'll note that I did not disable or unplug the wired Ethernet.

===
Mark Millard
markmi at dsl-only.net

On 2016-Jun-21, at 4:14 AM, Mark Millard  wrote:

> On 2016-Jun-21, at 3:33 AM, Keith White  wrote:
> 
>> On Tue, 21 Jun 2016, Mark Millard wrote:
>> 
>>> Otacílio otacilio.neto at bsd.com.br wrote on Tue Jun 21 00:06:39 UTC 2016 :
>>> 
> The kernel panic is totally reproducible. I need only do a ssh in the
> beaglebone using ptty on windows or ssh on freebsd and the kernel > panic 
> is raised.
>>> . . .
 FreeBSD11-ALPHA4 shows the same behavior. The only thing that I need to 
 raise the fault is ssh in the beaglebone.
>>> 
>>> (After this quotes are command input/output from my test activity.)
>>> 
>>> Under 11.0 -r310975 on a rpi2 I can ssh out of the rpi2 just fine. . .
>>> 
 # uname -apKU
 FreeBSD rpi2 11.0-ALPHA4 FreeBSD 11.0-ALPHA4 #1 r301975M: Thu Jun 16 
 18:12:02 PDT 2016 
 markmi@FreeBSDx64:/usr/obj/clang/arm.armv6/usr/src/sys/RPI2-NODBG  arm 
 armv6 1100117 1100117
>>> 
>>> 
>>> This is a no-debug kernel build (but with symbols). Details are given later 
>>> below.
>>> 
 # ssh markmi@192.168.0.105
 Password:
 Last login: Tue Jun 21 01:04:46 2016
 markmi$ 
>>> 
>>> Similarly I can ssh into the rpi2 from outside, here using new remote 
>>> connection in Mac OS X terminal: ssh 192.168.0.119 resulted in. . .
>>> 
 Password for markmi@rpi2:
 Last login: Mon May  9 19:27:33 2016 from 192.168.2.1
 FreeBSD 11.0-ALPHA4 (RPI2-NODBG) #1 r301975M: Thu Jun 16 18:12:02 PDT 2016
 Welcome to FreeBSD!
 Release Notes, Errata: https://www.FreeBSD.org/releases/
 Security Advisories:   https://www.FreeBSD.org/security/
 FreeBSD Handbook:  https://www.FreeBSD.org/handbook/
 FreeBSD FAQ:   https://www.FreeBSD.org/faq/
 Questions List: 
 https://lists.FreeBSD.org/mailman/listinfo/freebsd-questions/
 FreeBSD Forums:https://forums.FreeBSD.org/
 Documents installed with the system are in the 
 /usr/local/share/doc/freebsd/
 directory, or can be installed later with:  pkg install en-freebsd-doc
 For other languages, replace "en" with a language code like de or fr.
 Show the version of FreeBSD installed:  freebsd-version ; uname -a
 Please include that output and any error messages when posting questions.
 Introduction to manual pages:  man man
 FreeBSD directory layout:  man hier
 Edit /etc/motd to change this login announcement.
 To determine whether a file is a text file, executable, or some other type
 of file, use
 
file filen

Re: (beagleboneblack/urtwn) Kernel page fault with the following non-sleepable locks held [ssh on rpi2 comparison]

2016-06-21 Thread Mark Millard
On 2016-Jun-21, at 3:33 AM, Keith White  wrote:

> On Tue, 21 Jun 2016, Mark Millard wrote:
> 
>> Otacílio otacilio.neto at bsd.com.br wrote on Tue Jun 21 00:06:39 UTC 2016 :
>> 
>>> > The kernel panic is totally reproducible. I need only do a ssh in the
>>> > beaglebone using ptty on windows or ssh on freebsd and the kernel > panic 
>>> > is raised.
>> . . .
>>> FreeBSD11-ALPHA4 shows the same behavior. The only thing that I need to 
>>> raise the fault is ssh in the beaglebone.
>> 
>> (After this quotes are command input/output from my test activity.)
>> 
>> Under 11.0 -r310975 on a rpi2 I can ssh out of the rpi2 just fine. . .
>> 
>>> # uname -apKU
>>> FreeBSD rpi2 11.0-ALPHA4 FreeBSD 11.0-ALPHA4 #1 r301975M: Thu Jun 16 
>>> 18:12:02 PDT 2016 
>>> markmi@FreeBSDx64:/usr/obj/clang/arm.armv6/usr/src/sys/RPI2-NODBG  arm 
>>> armv6 1100117 1100117
>> 
>> 
>> This is a no-debug kernel build (but with symbols). Details are given later 
>> below.
>> 
>>> # ssh markmi@192.168.0.105
>>> Password:
>>> Last login: Tue Jun 21 01:04:46 2016
>>> markmi$ 
>> 
>> Similarly I can ssh into the rpi2 from outside, here using new remote 
>> connection in Mac OS X terminal: ssh 192.168.0.119 resulted in. . .
>> 
>>> Password for markmi@rpi2:
>>> Last login: Mon May  9 19:27:33 2016 from 192.168.2.1
>>> FreeBSD 11.0-ALPHA4 (RPI2-NODBG) #1 r301975M: Thu Jun 16 18:12:02 PDT 2016
>>> Welcome to FreeBSD!
>>> Release Notes, Errata: https://www.FreeBSD.org/releases/
>>> Security Advisories:   https://www.FreeBSD.org/security/
>>> FreeBSD Handbook:  https://www.FreeBSD.org/handbook/
>>> FreeBSD FAQ:   https://www.FreeBSD.org/faq/
>>> Questions List: 
>>> https://lists.FreeBSD.org/mailman/listinfo/freebsd-questions/
>>> FreeBSD Forums:https://forums.FreeBSD.org/
>>> Documents installed with the system are in the /usr/local/share/doc/freebsd/
>>> directory, or can be installed later with:  pkg install en-freebsd-doc
>>> For other languages, replace "en" with a language code like de or fr.
>>> Show the version of FreeBSD installed:  freebsd-version ; uname -a
>>> Please include that output and any error messages when posting questions.
>>> Introduction to manual pages:  man man
>>> FreeBSD directory layout:  man hier
>>> Edit /etc/motd to change this login announcement.
>>> To determine whether a file is a text file, executable, or some other type
>>> of file, use
>>> 
>>> file filename
>>> -- Dru 
>>> $ 
>> 
>> No panics or other odd notices.
>> 
>> The problem is apparently not general to all armv6 contexts.
>> 
>> Various context details follow. . .
>> 
>>> # more ~/src.configs/src.conf.rpi2-clang-bootstrap.rpi2-host TO_TYPE=armv6
>>> #
>>> KERNCONF=RPI2-NODBG
>>> TARGET=arm
>>> .if ${.MAKE.LEVEL} == 0
>>> TARGET_ARCH=${TO_TYPE}
>>> .export TARGET_ARCH
>>> .endif
>>> #
>>> #WITH_CROSS_COMPILER=
>>> WITH_SYSTEM_COMPILER=
>>> #
>>> #CPUTYPE=soft
>>> WITH_LIBSOFT=
>>> WITH_LIBCPLUSPLUS=
>>> WITH_BINUTILS_BOOTSTRAP=
>>> #WITHOUT_CLANG_BOOTSTRAP=
>>> WITH_CLANG=
>>> WITH_CLANG_IS_CC=
>>> WITH_CLANG_FULL=
>>> WITH_CLANG_EXTRAS=
>>> WITH_LLDB=
>>> #
>>> WITH_BOOT=
>>> WITHOUT_LIB32=
>>> #
>>> WITHOUT_ELFTOOLCHAIN_BOOTSTRAP=
>>> WITHOUT_GCC_BOOTSTRAP=
>>> WITHOUT_GCC=
>>> WITHOUT_GCC_IS_CC=
>>> WITHOUT_GNUCXX=
>>> #
>>> NO_WERROR=
>>> #WERROR=
>>> MALLOC_PRODUCTION=
>>> #
>>> WITH_DEBUG_FILES=
>>> #
>>> XCFLAGS+= -march=armv7-a -mcpu=cortex-a7
>>> XCXXFLAGS+= -march=armv7-a -mcpu=cortex-a7
>>> # There is no XCPPFLAGS but XCPP ets XCFLAGS content.
>> 
>> ~/src.configs/make.conf was empty.
>> 
>>> # more /usr/src/sys/arm/conf/RPI2-NODBG
>>> #
>>> # RPI2 -- Custom configuration for the Raspberry Pi 2
>>> #
>>> # For more information on this file, please read the config(5) manual page,
>>> # and/or the handbook section on Kernel Configuration Files:
>>> #
>>> #
>>> http://www.FreeBSD.org/doc/en_US.ISO8859-1/books/handbook/kernelconfig-config.html
>>> #
>>> # The handbook is also available locally in /usr/share/doc/handbook
>>> # if you've installed the doc distribution, otherwise always see the
>>> # FreeBSD World Wide Web server (http://www.FreeBSD.org/) for the
>>> # latest information.
>>> #
>>> # An exhaustive list of options and more detailed explanations of the
>>> # device lines is also present in the ../../conf/NOTES and NOTES files.
>>> # If you are in doubt as to the purpose or necessity of a line, check first
>>> # in NOTES.
>>> #
>>> ident   RPI2-NODBG
>>> include "RPI2"
>>> makeoptions DEBUG=-g# Build kernel with gdb(1) debug 
>>> symbols
>>> options ALT_BREAK_TO_DEBUGGER
>>> #optionsVERBOSE_SYSINIT # Enable verbose sysinit messages
>>> options KDB # Enable kernel debugger support
>>> # For minimum debugger support (stable branch) use:
>>> #optionsKDB_TRACE   # Print a stack trace for a panic
>>> options DDB # Enable the kernel debugger
>>> nooptions 

Re: (beagleboneblack/urtwn) Kernel page fault with the following non-sleepable locks held [ssh on rpi2 comparison]

2016-06-21 Thread Otacílio

Em 21/06/2016 07:33, Keith White escreveu:

In an earlier message Ian said that he thought he knew what the
problem was... 


Here the problem occurs  when using wifi. I do not have tested wired 
because I don't have a cable here.



[]'s

-Otacilio

___
freebsd-current@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"


Re: (beagleboneblack/urtwn) Kernel page fault with the following non-sleepable locks held [ssh on rpi2 comparison]

2016-06-21 Thread Keith White

On Tue, 21 Jun 2016, Mark Millard wrote:


Otacílio otacilio.neto at bsd.com.br wrote on Tue Jun 21 00:06:39 UTC 2016 :


> The kernel panic is totally reproducible. I need only do a ssh in the
> beaglebone using ptty on windows or ssh on freebsd and the kernel 
> panic is raised.

. . .
FreeBSD11-ALPHA4 shows the same behavior. The only thing that I need to 
raise the fault is ssh in the beaglebone.


(After this quotes are command input/output from my test activity.)

Under 11.0 -r310975 on a rpi2 I can ssh out of the rpi2 just fine. . .


# uname -apKU
FreeBSD rpi2 11.0-ALPHA4 FreeBSD 11.0-ALPHA4 #1 r301975M: Thu Jun 16 18:12:02 
PDT 2016 markmi@FreeBSDx64:/usr/obj/clang/arm.armv6/usr/src/sys/RPI2-NODBG  
arm armv6 1100117 1100117



This is a no-debug kernel build (but with symbols). Details are given later 
below.


# ssh markmi@192.168.0.105
Password:
Last login: Tue Jun 21 01:04:46 2016
markmi$ 


Similarly I can ssh into the rpi2 from outside, here using new remote 
connection in Mac OS X terminal: ssh 192.168.0.119 resulted in. . .


Password for markmi@rpi2:
Last login: Mon May  9 19:27:33 2016 from 192.168.2.1
FreeBSD 11.0-ALPHA4 (RPI2-NODBG) #1 r301975M: Thu Jun 16 18:12:02 PDT 2016

Welcome to FreeBSD!

Release Notes, Errata: https://www.FreeBSD.org/releases/
Security Advisories:   https://www.FreeBSD.org/security/
FreeBSD Handbook:  https://www.FreeBSD.org/handbook/
FreeBSD FAQ:   https://www.FreeBSD.org/faq/
Questions List: https://lists.FreeBSD.org/mailman/listinfo/freebsd-questions/
FreeBSD Forums:https://forums.FreeBSD.org/

Documents installed with the system are in the /usr/local/share/doc/freebsd/
directory, or can be installed later with:  pkg install en-freebsd-doc
For other languages, replace "en" with a language code like de or fr.

Show the version of FreeBSD installed:  freebsd-version ; uname -a
Please include that output and any error messages when posting questions.
Introduction to manual pages:  man man
FreeBSD directory layout:  man hier

Edit /etc/motd to change this login announcement.
To determine whether a file is a text file, executable, or some other type
of file, use

file filename
-- Dru 
$ 


No panics or other odd notices.

The problem is apparently not general to all armv6 contexts.

Various context details follow. . .

# more ~/src.configs/src.conf.rpi2-clang-bootstrap.rpi2-host 
TO_TYPE=armv6

#
KERNCONF=RPI2-NODBG
TARGET=arm
.if ${.MAKE.LEVEL} == 0
TARGET_ARCH=${TO_TYPE}
.export TARGET_ARCH
.endif
#
#WITH_CROSS_COMPILER=
WITH_SYSTEM_COMPILER=
#
#CPUTYPE=soft
WITH_LIBSOFT=
WITH_LIBCPLUSPLUS=
WITH_BINUTILS_BOOTSTRAP=
#WITHOUT_CLANG_BOOTSTRAP=
WITH_CLANG=
WITH_CLANG_IS_CC=
WITH_CLANG_FULL=
WITH_CLANG_EXTRAS=
WITH_LLDB=
#
WITH_BOOT=
WITHOUT_LIB32=
#
WITHOUT_ELFTOOLCHAIN_BOOTSTRAP=
WITHOUT_GCC_BOOTSTRAP=
WITHOUT_GCC=
WITHOUT_GCC_IS_CC=
WITHOUT_GNUCXX=
#
NO_WERROR=
#WERROR=
MALLOC_PRODUCTION=
#
WITH_DEBUG_FILES=
#
XCFLAGS+= -march=armv7-a -mcpu=cortex-a7
XCXXFLAGS+= -march=armv7-a -mcpu=cortex-a7
# There is no XCPPFLAGS but XCPP ets XCFLAGS content.


~/src.configs/make.conf was empty.


# more /usr/src/sys/arm/conf/RPI2-NODBG
#
# RPI2 -- Custom configuration for the Raspberry Pi 2
#
# For more information on this file, please read the config(5) manual page,
# and/or the handbook section on Kernel Configuration Files:
#
#
http://www.FreeBSD.org/doc/en_US.ISO8859-1/books/handbook/kernelconfig-config.html
#
# The handbook is also available locally in /usr/share/doc/handbook
# if you've installed the doc distribution, otherwise always see the
# FreeBSD World Wide Web server (http://www.FreeBSD.org/) for the
# latest information.
#
# An exhaustive list of options and more detailed explanations of the
# device lines is also present in the ../../conf/NOTES and NOTES files.
# If you are in doubt as to the purpose or necessity of a line, check first
# in NOTES.
#

ident   RPI2-NODBG

include "RPI2"

makeoptions DEBUG=-g# Build kernel with gdb(1) debug symbols
options ALT_BREAK_TO_DEBUGGER
#optionsVERBOSE_SYSINIT # Enable verbose sysinit messages

options KDB # Enable kernel debugger support

# For minimum debugger support (stable branch) use:
#optionsKDB_TRACE   # Print a stack trace for a panic
options DDB # Enable the kernel debugger

nooptions   INVARIANTS  # Enable calls of extra sanity checking
nooptions   INVARIANT_SUPPORT   # Extra sanity checks of internal 
structures, required by INVARIANTS
nooptions   WITNESS # Enable checks to detect deadlocks and 
cycles
nooptions   WITNESS_SKIPSPIN# Don't run witness on spinlocks for 
speed
nooptions   DIAGNOSTIC



My /usr/src tree has some changes/additions --but mostly for powerpc64 and 
powerpc issues:


# svnlite status /usr/src/
M   /usr/src/contrib/llvm/lib/CodeGen/Sele