Mike Hollis | 1 Dec 2010 23:47

svgalib kernel issues

 I googled my svgalib_helper  linux-2.6.36 problem and it was reported 
to  bugs.gentoo.org with the same error output I had.

error: unknown field ‘ioctl' specified in initializer

In  linux-2.6.36/include/fs.h  struct file_operations {...

the ioctl definition was removed  but there were unlocked_ioctl and
compat_ioctl . I checked linux-2.6.35.2 and all three were in fs.h.

I tried plugging in both unlocked_ioctl and compat_ioctl into the 
svgalib_helper code and the module compiled  but didn't work
correctly. Hopefully whoever maintains the package in gentoo
will come up with a patch.

 I backed up to linux-2.6.35.2 and have not seen any problems yet
concerning header compatibility. I wish I had known this when I
started my build.

 
--- Mike H. --- 

--

-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-chat
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page
Andrew Benton | 3 Dec 2010 01:05
Picon

Re: linux-2.6.37 defkeymap.c?

On Sun, 28 Nov 2010 12:08:39 -0500
Mike Hollis <zzflop <at> embarqmail.com> wrote:

>  I didn't realize you could compile a default into the kernel. What are
> the advantages of doing this as opposed to loading the keymap from boot
> scripts ?

If, in a crisis, you boot with init=/bin/bash, the bootscripts don't
get run and on top of everything else you have to cope with you have
the default American keymap. Which is fine if you're using an American
keyboard, not so good if you live somewhere else. Where's the tilde
sign gone? Where's the quotation mark?

Google was no use solving this, I had to figure it out from the kernel
source. It seems that in the 2.6.37 kernel the default keymap has moved
from drivers/char/defkeymap.c to drivers/tty/vt/defkeymap.c.
To compile a UK keymap into the kernel I now have to (just before I run
make):

loadkeys -m /usr/share/keymaps/i386/qwerty/uk.map.gz > \
  drivers/tty/vt/defkeymap.c

Andy
--

-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-chat
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page

Mike Hollis | 3 Dec 2010 04:11

Re: linux-2.6.37 defkeymap.c?

On Fri, Dec 03, 2010 at 12:05:31AM +0000, Andrew Benton wrote:
> On Sun, 28 Nov 2010 12:08:39 -0500
> Mike Hollis <zzflop <at> embarqmail.com> wrote:
> 
> >  I didn't realize you could compile a default into the kernel. What are
> > the advantages of doing this as opposed to loading the keymap from boot
> > scripts ?
> 
> If, in a crisis, you boot with init=/bin/bash, the bootscripts don't
> get run and on top of everything else you have to cope with you have
> the default American keymap. Which is fine if you're using an American
> keyboard, not so good if you live somewhere else. Where's the tilde
> sign gone? Where's the quotation mark?
> 
> Google was no use solving this, I had to figure it out from the kernel
> source. It seems that in the 2.6.37 kernel the default keymap has moved
> from drivers/char/defkeymap.c to drivers/tty/vt/defkeymap.c.
> To compile a UK keymap into the kernel I now have to (just before I run
> make):
> 
> loadkeys -m /usr/share/keymaps/i386/qwerty/uk.map.gz > \
>   drivers/tty/vt/defkeymap.c
> 
> Andy

 Yes, I see where that could be problematic. One would think that there
would be a kernel configuration option for such a fundamental item.

--- Mike H.--- 
--

-- 
(Continue reading)

Mike Hollis | 3 Dec 2010 18:36

Re: svgalib kernel issues

On Wed, Dec 01, 2010 at 05:47:55PM -0500, Mike Hollis wrote:
>  I googled my svgalib_helper  linux-2.6.36 problem and it was reported 
> to  bugs.gentoo.org with the same error output I had.
> 
> error: unknown field ‘ioctl' specified in initializer
> 
> In  linux-2.6.36/include/fs.h  struct file_operations {...
> 
> the ioctl definition was removed  but there were unlocked_ioctl and
> compat_ioctl . I checked linux-2.6.35.2 and all three were in fs.h.
> 
> I tried plugging in both unlocked_ioctl and compat_ioctl into the 
> svgalib_helper code and the module compiled  but didn't work
> correctly. Hopefully whoever maintains the package in gentoo
> will come up with a patch.
> 
>  I backed up to linux-2.6.35.2 and have not seen any problems yet
> concerning header compatibility. I wish I had known this when I
> started my build.
> 

 One final comment in the unlikely case someone besides me uses svgalib
in the lfs community. I overlooked a suggested patch in bugs.gentoo.org
and it worked with some line number modifications. I was on the right 
track with the ioctl change but gave up too quickly.

--- Mike H.---
--

-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-chat
FAQ: http://www.linuxfromscratch.org/faq/
(Continue reading)

Mike Hollis | 7 Dec 2010 20:30

Re: svgalib kernel issues

On Fri, Dec 03, 2010 at 12:36:39PM -0500, Mike Hollis wrote:
> On Wed, Dec 01, 2010 at 05:47:55PM -0500, Mike Hollis wrote:
> >  I googled my svgalib_helper  linux-2.6.36 problem and it was reported 
> > to  bugs.gentoo.org with the same error output I had.
> > 
> > error: unknown field ‘ioctl' specified in initializer
> > 
> > In  linux-2.6.36/include/fs.h  struct file_operations {...
> > 
> > the ioctl definition was removed  but there were unlocked_ioctl and
> > compat_ioctl . I checked linux-2.6.35.2 and all three were in fs.h.
> > 
> > I tried plugging in both unlocked_ioctl and compat_ioctl into the 
> > svgalib_helper code and the module compiled  but didn't work
> > correctly. Hopefully whoever maintains the package in gentoo
> > will come up with a patch.
> > 
> >  I backed up to linux-2.6.35.2 and have not seen any problems yet
> > concerning header compatibility. I wish I had known this when I
> > started my build.
> > 
>  
>  One final comment in the unlikely case someone besides me uses svgalib
> in the lfs community. I overlooked a suggested patch in bugs.gentoo.org
> and it worked with some line number modifications. I was on the right 
> track with the ioctl change but gave up too quickly.
> 
> 
> --- Mike H.---

(Continue reading)

Matthew Burgess | 21 Dec 2010 21:53
Picon
Favicon

General system problem solving tools

Hi all,

I've been trying to track a problem at work for the last couple
of days but my efforts have been scuppered by a general lack of
knowledge of low-ish level debugging/tracing tools.

The problem we have is that a closed-source multi-threaded program
we are using hits issues when we get it to spawn over roughly 250
threads.  I'm deliberately preserving the program's anonymity so
as to protect the (presumed) innocent at this point.

When the program fails, we end up with messages related to
failures in the select() call with both 'bad file descriptor' and
'invalid argument' errors.

At the moment, we're not sure whether this is a problem with the
closed source program, or with some user-space or kernel
configuration or bug.  The server we're running this on is a 4-CPU
quad-core, 16GB RAM box, so has plenty of grunt.  The program also
runs on a Windows laptop without any issues with 500 threads!

Obvious things like 'top' and 'df' don't show any problems.  I've
tried running a couple of systemtap scripts (the nettop and
socket-trace examples) but they don't appear to show much of any
use.  When I attach 'strace' to the running process, it just seems
to be hanging on futex_wait so I can't see any select() calls or
their arguments.

So, does anyone have any secrets in their sysadmin toolbox that
may be of use here?  Any help at all would be greatly appreciated,
(Continue reading)


Gmane