This set has various bug fixes and has nearly removed currcon. I also
moved data from console.h and console_struct.h into vt_kern.h. The move to
have struct vt_struct represent a display and struct vc_data represent the
set of VCs belonging to to a display. Also I'm begining the breakup of
console.c. The biggest change is struct kbd_struct has been moved into
struct vc_data.
This will break the following drivers:
drivers/sbus/char/sunkbd.c
drivers/macintosh/mac_keyb.c
drivers/sgi/char/streamable.c
Please port these drivers over to the input api. Soon I will move
keyboard.c over to the input api in the next few weeks anyways. This move
will break every keyboard driver not ported over to the input api.
diff:
http://www.transvirtual.com/~jsimmons/console.diff.gz
BK:
http://linuxconsole.bkbits.net:8080/dev
diffstat
drivers/char/Makefile | 12
drivers/char/console.c | 3032 -------------------------
drivers/char/console_macros.h | 155 -
drivers/char/consolemap.c | 121 -
drivers/char/keyboard.c | 583 ++--
drivers/char/misc.c | 1
drivers/char/selection.c | 21
drivers/char/sysrq.c | 486 ----
drivers/char/tty_io.c | 2
drivers/char/vc_screen.c | 105
drivers/char/vt.c | 4855 +++++++++++++++++++++++++++++++----------
drivers/video/dummycon.c | 1
drivers/video/fbcon-accel.c | 5
drivers/video/fbcon.c | 10
drivers/video/mdacon.c | 3
drivers/video/newport_con.c | 1
drivers/video/promcon.c | 23
drivers/video/sticon.c | 1
drivers/video/vgacon.c | 1
include/linux/console.h | 17
include/linux/console_struct.h | 110
include/linux/consolemap.h | 6
include/linux/kbd_kern.h | 26
include/linux/selection.h | 24
include/linux/tty.h | 2
include/linux/vt_kern.h | 172 +
include/video/fbcon.h | 2
27 files changed, 4550 insertions(+), 5227 deletions(-)
. ---
|o_o |
|:_/ | Give Micro$oft the Bird!!!!
// \ \ Use Linux!!!!
(| | )
/'\_ _/`\
\___)=(___/
On Mittwoch, 24. Juli 2002 22:08, James Simmons wrote:
> drivers/macintosh/mac_keyb.c
This one is obsolete for PPC (replaced by drivers/macintosh/adbhid.c),
probably the same is true for m68k. Remove it as soon as Geert gives his OK.
Franz.
On Wed, Jul 24, 2002 at 01:08:33PM -0700, James Simmons wrote:
> drivers/char/sysrq.c | 486 ----
Do you really mean to remove _all_ sysrq functionality from the kernel,
thereby removing an important debugging feature?
--
Russell King ([email protected]) The developer of ARM Linux
http://www.arm.linux.org.uk/personal/aboutme.html
> On Wed, Jul 24, 2002 at 01:08:33PM -0700, James Simmons wrote:
> > drivers/char/sysrq.c | 486 ----
>
> Do you really mean to remove _all_ sysrq functionality from the kernel,
> thereby removing an important debugging feature?
Oops. I forgot to do a bk -r co -q after the push. Will send out a newer
patch. Also I discovered a few missed files with the handle_sysrq change.
New patch in the works.
P.S
To the people with the devfs issues. Please send me a log of what
exactly happened and a detail ksymoop if you can. I just tried it on my
system with devfs enabled and it works for me.
On Wed, 24 Jul 2002, James Simmons wrote:
>
> To the people with the devfs issues. Please send me a log of what
> exactly happened and a detail ksymoop if you can. I just tried it on my
> system with devfs enabled and it works for me.
It doesn't oops, it just doesn't register the devices so you can't open
gettys on them. Other than that the kernel boots fine and you can log in
over the network. Doing that you can see a couple of big difference in
/dev:
2.5.28 without fix:
$ ls -l /dev/vc
total 0
crw------- 1 root root 4, 0 Jan 1 1970 0
$ ls -l /dev/tty*
crw-rw-rw- 1 root root 5, 0 Jan 1 1970 /dev/tty
lr-xr-xr-x 1 root root 4 Jul 25 14:17 /dev/tty0 -> vc/0
Whereas with the fix to add a call to con_init_devfs() near the end of
vty_init() it all works and you can see the following:
ls -l /dev/vc
total 0
crw------- 1 root root 4, 0 Jan 1 1970 0
crw------- 1 root root 4, 1 Jul 25 14:09 1
crw------- 1 root root 4, 10 Jan 1 1970 10
crw------- 1 root root 4, 11 Jan 1 1970 11
etc...
crw------- 1 root root 4, 63 Jan 1 1970 63
$ ls -l /dev/tty*
crw-rw-rw- 1 root root 5, 0 Jan 1 1970 /dev/tty
lr-xr-xr-x 1 root root 4 Jul 25 14:25 /dev/tty0 -> vc/0
lr-xr-xr-x 1 root root 4 Jul 25 14:25 /dev/tty1 -> vc/1
lr-xr-xr-x 1 root root 5 Jul 25 14:25 /dev/tty10 -> vc/10
lr-xr-xr-x 1 root root 5 Jul 25 14:25 /dev/tty11 -> vc/11
etc...
lr-xr-xr-x 1 root root 5 Jul 25 14:25 /dev/tty63 -> vc/63
If the system can still see static device nodes for the devices it can, of
course, still ue them even with devfs built into the kernel.
Ewan
On Thu, 25 Jul 2002, Ewan Mac Mahon wrote:
> On Wed, 24 Jul 2002, James Simmons wrote:
> >
> > To the people with the devfs issues. Please send me a log of what
> > exactly happened and a detail ksymoop if you can. I just tried it on my
> > system with devfs enabled and it works for me.
>
> It doesn't oops, it just doesn't register the devices so you can't open
> gettys on them. Other than that the kernel boots fine and you can log in
> over the network. Doing that you can see a couple of big difference in
> /dev:
I tracked down the problem. Originally the code initialized the VT tty
early before kmalloc. So we had this:
console_driver.flags |= TTY_DRIVER_NO_DEVFS;
Now in tty_register_driver, which was called right afterwards, we have
this bit of code.
if ( !(driver->flags & TTY_DRIVER_NO_DEVFS) ) {
for(i = 0; i < driver->num; i++)
tty_register_devfs(driver, 0, driver->minor_start + i);
}
In the old code code the above was never called. Instead the code in
con_init_devfs was called.
Now in the new code we don't have TTY_DRIVER_NO_DEVFS set so the above is
called. The problem is the default flag that is passed into
tty_register_devfs. It is automatically 0 whereas before it was
DEVFS_FL_AOPEN_NOTIFY. The problem is the flag being passed.
I tried out devfs and found the problem is only root is now only allowed
to access vc/X. This is the problem. I haven't figured out a solution yet.
Any ideas anyone?