Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 23 May 2020 02:30:40 -0700
From:      Mark Millard <marklmi@yahoo.com>
To:        bob prohaska <fbsd@www.zefox.net>
Cc:        Marcel Flores <marcel@brickporch.com>, freebsd-arm <freebsd-arm@freebsd.org>
Subject:   Re: Missing /dev/io on rpi3 running 12-stable
Message-ID:  <BE40E8FD-65C2-43AA-81B1-CFBDB6E8DDA1@yahoo.com>
In-Reply-To: <F2AF4DD6-599B-4032-A004-0A1B2BD2D727@brickporch.com>
References:  <20200520164642.GA70838@www.zefox.net> <CAJwjRmSmCEWCEbEr%2B14m6x04Xcx6j7Bgmp%2BHDkN5zsyAq=LExg@mail.gmail.com> <20200522172813.GA77725@www.zefox.net> <20200523051403.GA78879@www.zefox.net> <F2AF4DD6-599B-4032-A004-0A1B2BD2D727@brickporch.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On 2020-May-22, at 23:23, Marcel Flores <marcel at brickporch.com> =
wrote:

>=20
>> On May 22, 2020, at 10:14 PM, bob prohaska <fbsd@www.zefox.net> =
wrote:
>>=20
>> On Fri, May 22, 2020 at 10:28:13AM -0700, bob prohaska wrote:
>>> On Fri, May 22, 2020 at 06:38:40PM +0200, Mika??l Urankar wrote:
>>>> Le mer. 20 mai 2020 ?? 18:46, bob prohaska <fbsd@www.zefox.net> a =
??crit :
>>>>>=20
>>>>> Is there supposed to be a /dev/io by default in FreeBSD on a Pi3?
>>>>> Attempts to start X under 12.1-STABLE r361271 GENERIC fail with
>>>>> a report of "failed to open /dev/io". There is indeed no /dev/io,
>>>>> but there's also no /dev/io on a pi2 running 12-stable.
>>>>>=20
>>>>> Nor does there seem to be  a kernel module with matching name....
>>>>=20
>>>> I looked at the code and it's only a warning:
>>>> if ((IoFd =3D open("/dev/io", O_RDWR)) =3D=3D -1) {
>>>>       xf86Msg(X_WARNING, "xf86EnableIO: "
>>>>               "Failed to open /dev/io for extended I/O\n");
>>>>=20
>>>> Can you post the whole Xorg log somewhere?
>>>>=20
>>>=20
>>> I'm in the process now of cleaning up, deinstalling everything and
>>> starting over, this time using -DBATCH from the start. The whole
>>> fiasco started when I succumbed to the temptations offered by
>>> dialog4ports (docs are good, amdgpu on a Pi made no sense).
>>>=20
>>> At the very least it'll bring the system to a reproducible state.=20
>>>=20
>> The cleanup is complete, running the command=20
>> X -configure=20
>> as root put in the logfile=20
>> root@nemesis:~ # more /var/log/Xorg.0.log
>> [252792.514]=20
>> X.Org X Server 1.20.8
>> X Protocol Version 11, Revision 0
>> [252792.515] Build Operating System: FreeBSD 12.1-STABLE arm64=20
>> [252792.515] Current Operating System: FreeBSD nemesis.zefox.com =
12.1-STABLE FreeBSD 12.1-STABLE r361271 GENERIC arm64
>> [252792.517] Build Date: 22 May 2020  09:25:08PM
>> [252792.517] =20
>> [252792.517] Current version of pixman: 0.40.0
>> [252792.517]    Before reporting problems, check http://wiki.x.org
>>       to make sure that you have the latest version.
>> [252792.517] Markers: (--) probed, (**) from config file, (=3D=3D) =
default setting,
>>       (++) from command line, (!!) notice, (II) informational,
>>       (WW) warning, (EE) error, (NI) not implemented, (??) unknown.
>> [252792.518] (=3D=3D) Log file: "/var/log/Xorg.0.log", Time: Fri May =
22 21:50:03 2020
>> [252792.518] (II) Loader magic: 0x43a5e0
>> [252792.518] (II) Module ABI versions:
>> [252792.518]    X.Org ANSI C Emulation: 0.4
>> [252792.518]    X.Org Video Driver: 24.1
>> [252792.518]    X.Org XInput driver : 24.1
>> [252792.518]    X.Org Server Extension : 10.0
>> [252792.520] List of video drivers:
>> [252792.520]    scfb
>> [252792.520]    modesetting
>> [252792.520] (II) LoadModule: "scfb"
>> [252792.521] (II) Loading =
/usr/local/lib/xorg/modules/drivers/scfb_drv.so
>> [252792.521] (II) Module scfb: vendor=3D"X.Org Foundation"
>> [252792.521]    compiled for 1.20.8, module version =3D 0.0.5
>> [252792.521]    ABI class: X.Org Video Driver, version 24.1
>> [252792.521] (II) LoadModule: "modesetting"
>> [252792.522] (II) Loading =
/usr/local/lib/xorg/modules/drivers/modesetting_drv.so
>> [252792.522] (II) Module modesetting: vendor=3D"X.Org Foundation"
>> [252792.522]    compiled for 1.20.8, module version =3D 1.20.8
>> [252792.523]    Module class: X.Org Video Driver
>> [252792.523]    ABI class: X.Org Video Driver, version 24.1
>> [252792.523] (WW) xf86EnableIO: Failed to open /dev/io for extended =
I/O
>> [252792.523] (WW) Falling back to old probe method for scfb
>> [252792.523] scfb trace: probe start
>> [252792.523] (WW) Falling back to old probe method for modesetting
>> [252792.523] No devices to configure.  Configuration failed.
>> [252792.524] (EE) Server terminated with error (2). Closing log file.
>>=20
>> That repeats the missing /dev/io error seen previously.
>>=20
>> Another correspondent asked what happens if startx is run
>> by a regular user on the console. That log file is different:
>>=20
>> root@nemesis:~ # more /var/log/Xorg.1.log
>> [253234.555]=20
>> X.Org X Server 1.20.8
>> X Protocol Version 11, Revision 0
>> [253234.556] Build Operating System: FreeBSD 12.1-STABLE arm64=20
>> [253234.556] Current Operating System: FreeBSD nemesis.zefox.com =
12.1-STABLE FreeBSD 12.1-STABLE r361271 GENERIC arm64
>> [253234.557] Build Date: 22 May 2020  09:25:08PM
>> [253234.557] =20
>> [253234.558] Current version of pixman: 0.40.0
>> [253234.558]    Before reporting problems, check http://wiki.x.org
>>       to make sure that you have the latest version.
>> [253234.558] Markers: (--) probed, (**) from config file, (=3D=3D) =
default setting,
>>       (++) from command line, (!!) notice, (II) informational,
>>       (WW) warning, (EE) error, (NI) not implemented, (??) unknown.
>> [253234.558] (=3D=3D) Log file: "/var/log/Xorg.1.log", Time: Fri May =
22 21:57:25 2020
>> [253234.559] (=3D=3D) Using config directory: =
"/usr/local/etc/X11/xorg.conf.d"
>> [253234.560] (=3D=3D) Using system config directory =
"/usr/local/share/X11/xorg.conf.d"
>> [253234.561] (=3D=3D) No Layout section.  Using the first Screen =
section.
>> [253234.561] (=3D=3D) No screen section available. Using defaults.
>> [253234.561] (**) |-->Screen "Default Screen Section" (0)
>> [253234.561] (**) |   |-->Monitor "<default monitor>"
>> [253234.563] (=3D=3D) No device specified for screen "Default Screen =
Section".
>>       Using the first device section listed.
>> [253234.563] (**) |   |-->Device "Card0"
>> [253234.563] (=3D=3D) No monitor specified for screen "Default Screen =
Section".
>>       Using a default monitor configuration.
>> [253234.563] (=3D=3D) Automatically adding devices
>> [253234.563] (=3D=3D) Automatically enabling devices
>> [253234.563] (=3D=3D) Not automatically adding GPU devices
>> [253234.563] (=3D=3D) Max clients allowed: 256, resource mask: =
0x1fffff
>> [253234.564] (=3D=3D) FontPath set to:
>>       /usr/local/share/fonts/misc/,
>>       /usr/local/share/fonts/TTF/,
>>       /usr/local/share/fonts/OTF/,
>>       /usr/local/share/fonts/Type1/,
>>       /usr/local/share/fonts/100dpi/,
>>       /usr/local/share/fonts/75dpi/,
>>       catalogue:/usr/local/etc/X11/fontpath.d
>> [253234.564] (=3D=3D) ModulePath set to "/usr/local/lib/xorg/modules"
>> [253234.564] (II) The server relies on udev to provide the list of =
input devices.
>>       If no devices become available, reconfigure udev or disable =
AutoAddDevices.
>> [253234.564] (II) Loader magic: 0x43a5e0
>> [253234.564] (II) Module ABI versions:
>> [253234.564]    X.Org ANSI C Emulation: 0.4
>> [253234.564]    X.Org Video Driver: 24.1
>> [253234.564]    X.Org XInput driver : 24.1
>> [253234.564]    X.Org Server Extension : 10.0
>> [253234.565] (II) LoadModule: "glx"
>> [253234.565] (II) Loading =
/usr/local/lib/xorg/modules/extensions/libglx.so
>> [253234.576] (II) Module glx: vendor=3D"X.Org Foundation"
>> [253234.576]    compiled for 1.20.8, module version =3D 1.0.0
>> [253234.576]    ABI class: X.Org Server Extension, version 10.0
>> [253234.576] (II) LoadModule: "scfb"
>> [253234.576] (II) Loading =
/usr/local/lib/xorg/modules/drivers/scfb_drv.so
>> [253234.577] (II) Module scfb: vendor=3D"X.Org Foundation"
>> [253234.577]    compiled for 1.20.8, module version =3D 0.0.5
>> [253234.577]    ABI class: X.Org Video Driver, version 24.1
>> [253234.577] (II) scfb: driver for wsdisplay framebuffer: scfb
>> [253234.578] (--) Using syscons driver with X support (version 2.0)
>> [253234.578] (--) using VT number 9
>>=20
>> [253234.578] (WW) Falling back to old probe method for scfb
>> [253234.578] scfb trace: probe start
>> [253234.578] (II) scfb(0): using default device
>> [253234.578] scfb trace: probe done
>> [253234.578] (WW) VGA arbiter: cannot open kernel arbiter, no =
multi-card support
>> [253234.578] scfb: PreInit 0
>> [253234.578] (II) scfb(0): Using: depth (24),   width (1920),    =
height (1200)
>> [253234.578] (EE) scfb(0): Specified fbbpp (24) is not a permitted =
value
>> [253234.579] (II) UnloadModule: "scfb"
>> [253234.579] (EE) Screen(s) found, but none have a usable =
configuration.
>> [253234.579] (EE)=20
>> Fatal server error:
>> [253234.579] (EE) no screens found(EE)=20
>> [253234.579] (EE)=20
>> Please consult the The X.Org Foundation support=20
>>        at http://wiki.x.org
>> for help.=20
>> [253234.579] (EE) Please also check the log file at =
"/var/log/Xorg.1.log" for additional information.
>> [253234.579] (EE)=20
>> [253234.580] (EE) Server terminated with error (1). Closing log file.
>> --More--(END)
>>=20
>> The gripe about 24bpp being "not permitted" looks wrong, unless =
there's
>> not enough video memory allocated.
>>=20
>> Having different failures for different users strikes me as very odd.
>> It rather suggests a permissions problem, but permissions aren't=20
>> mentioned in the logs.
>>=20
>> If you can think of something to test please instruct.
>>=20
>> Thanks for reading,
>>=20
>> bob prohaska
>>=20
>> _______________________________________________
>> freebsd-arm@freebsd.org mailing list
>> https://lists.freebsd.org/mailman/listinfo/freebsd-arm
>> To unsubscribe, send any mail to =
"freebsd-arm-unsubscribe@freebsd.org=E2=80=9D
>=20
>=20
> Seems like the later error is the same as described here:
>=20
> https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D246319 =
<https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D246319>;
>=20
> and
>=20
> https://lists.freebsd.org/pipermail/freebsd-arm/2020-May/021596.html =
<https://lists.freebsd.org/pipermail/freebsd-arm/2020-May/021596.html>;

I found the RPi3 (and related) fix in FreeBSD
head's sys/arm/broadcom/bcm2835/bcm2835_fbd.c :

QUOTE
Revision 352028 - (view) (download) (annotate) - [select for diffs]=20
Modified Sun Sep 8 09:47:21 2019 UTC (8 months, 2 weeks ago) by gonzo=20
File length: 7261 byte(s)=20
Diff to previous 331229
[rpi] Inherit framebuffer BPP value from the VideoCore firmware

Instead of using hardcoded bpp of 24, obtain current/configured value
from VideoCore. This solves certain problems with Xorg/Qt apps that
require bpp of 32 to work properly. The mode can be forced by setting
framebuffer_depth value in config.txt

PR:		235363
Submitted by:	Steve Peurifoy <ssw01@mathistry.net>
END QUOTE

The change leads to my RPi3 boot context reporting
what is used as:

fb0: <BCM2835 VT framebuffer driver> on simplebus0
fb0: keeping existing fb bpp of 32

So: efifb's figure was picked up by fb and then
fb's figure was picked up by scfb.

Conclusion: An MFC to older contexts would be appropriate.


=3D=3D=3D
Mark Millard
marklmi at yahoo.com
( dsl-only.net went
away in early 2018-Mar)




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?BE40E8FD-65C2-43AA-81B1-CFBDB6E8DDA1>