Re: U5 - Sarge with d-i rc2 netinstall failure

2004-12-02 Thread Nicolas Will

Joshua Kwan wrote:


Nicolas Will wrote:
|Partition check:
|hda:end_request: I/O error, dev 03:00 (hda), sector 0
|end_request: I/O error, dev 03:00 (hda), sector 2

This'll be fixed soon, I knew about it a while ago and was simply
waiting for a new Debian kernel source upload including security fixes
to be uploaded. Looks like that has just happened, so things are
forthcoming.

|cramfs: wrong magic

Similarly, this was just fixed.



Kernel bugs ? d-i bugs ?

Stay tuned... 



I will ! Any timeline ? Should I use a daily build of d-i when ready ?

Thanks for the replies, to you and Martin.

Now on to reading about 2.6's status on Sparc64...

--
Nico
http://rdo.homelinux.org



Re: U5 - Sarge with d-i rc2 netinstall failure

2004-12-02 Thread Joshua Kwan

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Nicolas Will wrote:
|Partition check:
|hda:end_request: I/O error, dev 03:00 (hda), sector 0
|end_request: I/O error, dev 03:00 (hda), sector 2

This'll be fixed soon, I knew about it a while ago and was simply
waiting for a new Debian kernel source upload including security fixes
to be uploaded. Looks like that has just happened, so things are
forthcoming.

|cramfs: wrong magic

Similarly, this was just fixed.

Stay tuned...

- --
Joshua Kwan
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.2.5 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iQIVAwUBQa/RIaOILr94RG8mAQLGkw/8CLgdPNFTbWQSRKpcdC56BLq0lT9fbl6p
8r7O65j2DgtjZoc3rDhUEwyMdHA71ZJBunYMDmWPyOYzfvM6uKfpbJOO/YkXuIK5
Xz4khzurDcojzCdDkeAmZHKDbENa8YxTqP+rtKd3D9crJz4velnOp5uVPKrK1v6P
xqCC5MXOmsfXrK5p6WRDj4ju2ySIGnt1xRdl4KU6hpP21ZP3G9GaseSn1bHtD1x+
HGqkjHzxZhXxf90Nk+UerFqPtIDH8fCQ0dnc+1iVhrpn8a7cjzygjMFZ3IWMKBjG
U+pM6+2huN/rB+UKNuaRRRctw3w/wFUvw8hPqY9QIOuJIkwh8xq/KfZ3Er2cb6tk
nL7JbjdzE996pzx1aV6fcKHzkr4mkefi8C4ZtAs+pekBTH6Twc1X1n28zI4MhhxX
goYFY+SEsO3lRXVAkOw07ANuP2Uxl3oCrWGQpW6cxKm3N5xs0MDt/fxyeGZ1XG71
C+73GmR+n4F0PLKYiNneogqjWSA4QvxY/UOp2G2f5lMybe74QU+szkC9llUis8Cv
yrZo2ouD2v6pXVEYIYhW8zoXQOTXV7dEO8WhspIFy1q3WfSB9jnwODJ3Io+NQyjf
0ex2SkYwyuIpYmOxVEN2xwHeWF4whu9gpMQiIGcOkUPD2+TmKnsk6OaJyPXf94vL
b4Tfunm0i/4=
=6Q6v
-END PGP SIGNATURE-



Re: U5 - Sarge with d-i rc2 netinstall failure

2004-12-02 Thread Martin
> I'm trying to get Sarge on a plain vanilla Ultra 5.
> 
> I'm using the RC2 release of the Debian-Installer Net-Install CD.
> 
> I end up with the following:

> Partition check:
> hda:end_request: I/O error, dev 03:00 (hda), sector 0
> end_request: I/O error, dev 03:00 (hda), sector 2
> end_request: I/O error, dev 03:00 (hda), sector 4
> end_request: I/O error, dev 03:00 (hda), sector 6
> end_request: I/O error, dev 03:00 (hda), sector 8
> end_request: I/O error, dev 03:00 (hda), sector 10
> end_request: I/O error, dev 03:00 (hda), sector 12
> end_request: I/O error, dev 03:00 (hda), sector 14
> end_request: I/O error, dev 03:00 (hda), sector 0
> end_request: I/O error, dev 03:00 (hda), sector 2
> end_request: I/O error, dev 03:00 (hda), sector 4
> end_request: I/O error, dev 03:00 (hda), sector 6
> end_request: I/O error, dev 03:00 (hda), sector 8
> end_request: I/O error, dev 03:00 (hda), sector 10
> end_request: I/O error, dev 03:00 (hda), sector 12
> end_request: I/O error, dev 03:00 (hda), sector 14
> unable to read partition table

> I've read hints of boot parameters involving devfs, but nothing real 
> definitive on that.
> 
> Can anybody nudge me in the right direction?
Sounds to me like a dead disk.  Do you know for sure whether the disk
you have in the Ultra 5 works?  It might also be worth checking the
archives for info on the problems with the IDE chip on Ultra-5's.  IIRC
the chip is buggy and some combinations of DMA and ATA speeds cause evil
things to happen.

HTH

Cheers,
 - Martin

-- 
Martin
[EMAIL PROTECTED]
"Seasons change, things come to pass"



U5 - Sarge with d-i rc2 netinstall failure

2004-12-02 Thread Nicolas Will

Hi all,

I'm trying to get Sarge on a plain vanilla Ultra 5.

I'm using the RC2 release of the Debian-Installer Net-Install CD.

I end up with the following:

   ok boot cdrom
   Resetting ...


   Sun Ultra 5/10 UPA/PCI (UltraSPARC-IIi 270MHz), No Keyboard
   OpenBoot 3.11, 128 MB memory installed, Serial #10493455.
   Ethernet address 8:0:20:a0:1e:f, Host ID: 80a01e0f.



   Rebooting with command: boot cdrom
   Boot device: /[EMAIL PROTECTED],0/[EMAIL PROTECTED],1/[EMAIL 
PROTECTED]/[EMAIL PROTECTED],0:f File and args:
   SILO Version 1.4.8
   \


   Welcome to Debian GNU/Linux sarge!

   This is a Debian installation CDROM, built on 20041121.
   Keep it once you have installed your system, as you can boot from it
   to repair the system on your hard disk if that ever becomes necessary.

   WARNING: You should completely back up all of your hard disks before
   proceeding. The installation procedure can completely and irreversibly
   erase them! If you haven't made backups yet, remove the rescue CD from
   the drive and press L1-A to get back to the OpenBoot prompt.

   Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
   permitted
   by applicable law.

   [ ENTER - Boot install ] [ Type "rescue" - Boot into rescue mode ]
   boot:
   Allocated 8 Megs of memory at 0x4000 for kernel
   Loaded kernel version 2.4.27
   Loading initial ramdisk (2896142 bytes at 0x17C02000 phys,
   0x40C0 virt)...
   |
   Remapping the kernel... Booting Linux...
   PROMLIB: Sun IEEE Boot Prom 3.11.12 1998/05/19 11:30
   Linux version 2.4.27-1-sparc64 ([EMAIL PROTECTED])
   (gcc version 3
   .3.4 (Debian 1:3.3.4-7)) #1 Mon Aug 23 23:59:55 PDT 2004
   ARCH: SUN4U
   Ethernet address: 08:00:20:a0:1e:0f
   On node 0 totalpages: 15521
   zone(0): 16293 pages.
   zone(1): 0 pages.
   zone(2): 0 pages.
   Found CPU 0 (node=f006ce08,mid=0)
   Found 1 CPU prom device tree node(s).
   Kernel command line: root=/dev/rd/0 cdrom ramdisk_size=16384
   devfs=mount rw
   Calibrating delay loop... 539.03 BogoMIPS
   Memory: 122600k available (1880k kernel code, 296k data, 160k init)
   [f80
   0,17f4a000]
   Dentry cache hash table entries: 16384 (order: 5, 262144 bytes)
   Inode cache hash table entries: 8192 (order: 4, 131072 bytes)
   Mount cache hash table entries: 512 (order: 0, 8192 bytes)
   Buffer cache hash table entries: 1024 (order: 0, 8192 bytes)
   Page-cache hash table entries: 16384 (order: 4, 131072 bytes)
   POSIX conformance testing by UNIFIX
   PCI: Probing for controllers.
   PCI: Found SABRE, main regs at 01fe, wsync at
   01fe1c20
   SABRE: Shared PCI config space at 01fe0100
   SABRE: DVMA at c000 [2000]
   PCI0(PBMA): Bus running at 33MHz
   PCI-IRQ: Routing bus[ 1] slot[ 1] map[0] to INO[21]
   PCI-IRQ: Routing bus[ 1] slot[ 2] map[0] to INO[0f]
   PCI-IRQ: Routing bus[ 1] slot[ 3] map[0] to INO[20]
   PCI0(PBMB): Bus running at 33MHz
   ebus0: [auxio] [power] [SUNW,pll] [se] [su] [su] [ecpp] [fdthree]
   [eeprom] [flas
   hprom] [SUNW,CS4231]
   PCIO serial driver version 1.54
   su(mouse) at 0x1fff13062f8 (irq = 4,7ea) is a 16550A
   Sun Mouse-Systems mouse driver version 1.00
   su(kbd) at 0x1fff13083f8 (irq = 9,7e9) is a 16550A
   keyboard: not present
   SAB82532 serial driver version 1.65
   ttyS00 at 0x1fff140 (irq = 12,7eb) is a SAB82532 V3.2
   ttyS01 at 0x1fff1400040 (irq = 12,7eb) is a SAB82532 V3.2
   Console: ttyS0 (SAB82532)
   power: Control reg at 01fff1724000 ... powerd running.
   Linux NET4.0 for Linux 2.4
   Based upon Swansea University Computer Society NET3.039
   Initializing RT netlink socket
   Starting kswapd
   VFS: Disk quotas vdquot_6.5.1
   alloc_area_pte: page already exists
   alloc_area_pte: page already exists
   devfs: v1.12c (20020818) Richard Gooch ([EMAIL PROTECTED])
   devfs: boot_options: 0x1
   pty: 256 Unix98 ptys configured
   rtc_init: no PC rtc found
   Floppy drive(s): fd0 is 1.44M
   FDC 0 is a National Semiconductor PC87306
   RAMDISK driver initialized: 16 RAM disks of 16384K size 1024 blocksize
   Uniform Multi-Platform E-IDE driver Revision: 7.00beta4-2.4
   ide: Assuming 33MHz system bus speed for PIO modes; override with
   idebus=xx
   CMD646: IDE controller at PCI slot 01:03.0
   CMD646: chipset revision 3
   CMD646: chipset revision 0x03, MultiWord DMA Force Limited
   CMD646: 100% native mode on irq 4,7e0
   ide0: BM-DMA at 0x1fe02c00020-0x1fe02c00027, BIOS settings: hda:pio,
   hdb:pio
   ide1: BM-DMA at 0x1fe02c00028-0x1fe02c0002f, BIOS settings: hdc:pio,
   hdd:pio
   hda: ST34342A, ATA DISK drive
   ide: Assuming 33MHz system bus speed for PIO modes; override with
   idebus=xx
   hdc: CRD-8240B, ATAPI CD/DVD-ROM drive
   ide0 at 0x1fe02c0-0x1fe02c7,0x1fe02ca on irq 4,7e0
   ide1 at 0x1fe02c00010-0x1fe02c00017,0x1fe02c0001a on irq 4,7e0
   (shared with ide0
   )
   Partition check:
   hda:end_request: I/O error, dev 03:00 (hda), sector 0
   end_request: I/O e

Re: XFree crashing on kernel 2.4.28

2004-12-02 Thread Jurij Smakov

On Thu, 2 Dec 2004 [EMAIL PROTECTED] wrote:


[EMAIL PROTECTED]:~# ls /proc/bus/pci
:00  :01  :02  devices
[EMAIL PROTECTED]:~#

It appears that this patch will be ineffective for my problem if I
understand properly what it is doing.


Yes, I'm afraid so. I really hope that Richard's idea will work out 
(good work, btw).


Jurij Smakov[EMAIL PROTECTED]
Key: http://www.wooyd.org/pgpkey/   KeyID: C99E03CC



Re: X11 crashing on 2.4.28

2004-12-02 Thread Ron Murray
At Thu, 02 Dec 2004 22:41:46 +,
Richard Mortimer <[EMAIL PROTECTED]> wrote:
> 
> 
> On Thu, 2004-12-02 at 19:27, Ron Murray wrote:
> > At Thu, 02 Dec 2004 13:45:59 -0500,
> > Ron Murray wrote:
> >We have a minor problem. Richard's patch seems to refer to a
> > pristine xfree86-4.3.0 source.
> 
> Damn! There are two similar #if defined lines. I made the patch against
> the wrong one!
> 
> I also accept that I did make the patch against pristine sources -
> although in this case it means that you spotted my mistake.
> 
> I still stand by my analysis. Hopefully the new patch (below) will work.
> Note I've taken the same approach as the one that my original patch
> clashed with. Basically I've removed the check for ia64 because I'm
> assuming that the non-executable issue could in future apply to all
> linux versions.
> 
> Richard

   Yep, I agree that you've probably found the problem. After I wrote
my previous post, I did some poking around with gdb on the XFree86
executable. I found a sequence of bytes that looked a lot like the
ones you posted earlier, a little further on than you had (but my
current copy of XFree86 has lots of debugging code inbuilt). They even
had a call to malloc() in the middle of them. gdb claimed that the
code was in the middle of ELFLoadModule(), so I looked, and there it
was, complete with the same #ifdef you found earlier. I set up the
patch, started the build, and went home. With any luck, I'll have a
new (and hopefully functional) set of X packages when I get to work in
the morning.

   Only difference was that I didn't turn it on for all Linux, just
for ia86 and sparc. Wasn't sure whether it was a good idea or not.

   I'll let everyone know how it went. Thanks for finding it.

 .Ron

--
Ron Murray   ([EMAIL PROTECTED])
http://www.rjmx.net/~ron
GPG Public Key Fingerprint: F2C1 FC47 5EF7 0317 133C  D66B 8ADA A3C4 D86C 74DE



Re: XFree crashing on kernel 2.4.28

2004-12-02 Thread foo_bar_baz_boo-deb
Mr. Smakov,

[EMAIL PROTECTED]:~# ls /proc/bus/pci
:00  :01  :02  devices
[EMAIL PROTECTED]:~#

It appears that this patch will be ineffective for my problem if I
understand properly what it is doing.

--- Jurij Smakov <[EMAIL PROTECTED]> wrote:

> On Wed, 1 Dec 2004, Ron Murray wrote:
> 
> >   Colour me doubtful about this as a fix. Its bug report has an
> XFree86.log 
> > that actually appears to scan the PCI bus, then does lots of other
> things 
> > before reporting "no screens found". In contrast, both the logs
> from the 
> > originator of this thread and the XFree86.log in bug #280384 show
> the crash 
> > occurring immediately after loading the pcidata module, with no
> attempt to 
> > scan the PCI bus. That is also my experience, as evidenced by the
> log in my 
> > own post to bug #280384. They don't look like the same problem to
> me at all.
> 
> Hi,
> 
> I have looked more carefully at bug 279436. The fix which Branden
> Robinson 
> referred to was supposed to take care of the problem on sparc64 when
> the 
> machine does not have a PCI bus numbered zero. Can those who
> experienced 
> the crashes please post the contents of their /proc/bus/pci
> directory? If 
> it looks like this:
> 
> $ ls /proc/bus/pci/
> 40/  60/  80/  81/  devices
> 
> i.e. there is no '00' entry, then there is hope, that the patch will 
> actually do something useful. If there is a '00' entry, then we are 
> looking at a completely different problem.
> 
> Best regards,
> 
> Jurij Smakov[EMAIL PROTECTED]
> Key: http://www.wooyd.org/pgpkey/   KeyID: C99E03CC
> 
> 
> -- 
> To UNSUBSCRIBE, email to [EMAIL PROTECTED]
> with a subject of "unsubscribe". Trouble? Contact
> [EMAIL PROTECTED]
> 
> 



Re: debian on a sun enterprise 250

2004-12-02 Thread Huston
Title: debian on a sun enterprise 250



The light comes on only when I boot into Linux 
on the E250 I have.  I don't have the blinking during post.  I am 
going to try to patch it with a file that Eric Brower gave me.  I haven't 
installed it yet.  You may want to do a check on the machine if it is 
giving you this light during post.  Mine is all off through that stage and 
comes on and stays on after booting to Linux.  There are probably others 
here with more knowledge on it than I.  I will post my results on the 
patch, if I don't screw the machine up doing it.  Thanks again 
Eric.
 
Shawn Huston
 

  - Original Message - 
  From: 
  james 
  derry 
  To: debian-sparc@lists.debian.org 
  
  Sent: Thursday, December 02, 2004 4:22 
  PM
  Subject: [Norton AntiSpam] debian on a 
  sun enterprise 250
  
  i've already posted this on debian-user@lists.debian.org 
  and was advised to post it here. please forgive duplication, if you've already 
  received this message.i've recently taken over sysadmin duties for a 
  sun enterprise 250 running debian. the 250's has frontpanels LEDs, and one on 
  this machine, the general fault LED, burns constant yellow. online 
  documentation for the hardware at http://sunsolve.sun.com/handbook_pub/General/LEDs/E250_LEDs.html 
  says:This yellow LED blinks slowly while the system runs its power-on 
  self-test (POST) diagnostics and blinks rapidly during OpenBoot diagnostic 
  (OBDiag) tests. It lights steadily when any fault is detected (including a 
  fault also reported by any other LED).Q: could this be a normal state 
  for enterprise 250s running debian? or is the LED truly reporting that a fault 
  has been 
detected?thanks,james


Re: debian on a sun enterprise 250

2004-12-02 Thread Eric Brower
[cc'd to [EMAIL PROTECTED]

Take a look at my post regarding this issue:

http://lists.debian.org/debian-sparc/2004/11/msg2.html

I'll offer you the envctrltwo driver as well, with the understanding
that there are a few remaining issues to be addressed.  I can't seem
to find willing testers, despite several requests.

E


On Thu, 2 Dec 2004 15:22:14 -0600, james derry <[EMAIL PROTECTED]> wrote:
>  
> 
> i've already posted this on debian-user@lists.debian.org and was advised to
> post it here. please forgive duplication, if you've already received this
> message.
>  
>  i've recently taken over sysadmin duties for a sun enterprise 250 running
> debian. the 250's has frontpanels LEDs, and one on this machine, the general
> fault LED, burns constant yellow. online documentation for the hardware at
> http://sunsolve.sun.com/handbook_pub/General/LEDs/E250_LEDs.html says:
>  
>  This yellow LED blinks slowly while the system runs its power-on self-test
> (POST) diagnostics and blinks rapidly during OpenBoot diagnostic (OBDiag)
> tests. It lights steadily when any fault is detected (including a fault also
> reported by any other LED).
>  
>  Q: could this be a normal state for enterprise 250s running debian? or is
> the LED truly reporting that a fault has been detected?
>  
>  thanks,
>  james
>  


-- 
E



Re: X11 crashing on 2.4.28

2004-12-02 Thread Richard Mortimer

On Thu, 2004-12-02 at 19:27, Ron Murray wrote:
> At Thu, 02 Dec 2004 13:45:59 -0500,
> Ron Murray wrote:
>We have a minor problem. Richard's patch seems to refer to a
> pristine xfree86-4.3.0 source.

Damn! There are two similar #if defined lines. I made the patch against
the wrong one!

I also accept that I did make the patch against pristine sources -
although in this case it means that you spotted my mistake.

I still stand by my analysis. Hopefully the new patch (below) will work.
Note I've taken the same approach as the one that my original patch
clashed with. Basically I've removed the check for ia64 because I'm
assuming that the non-executable issue could in future apply to all
linux versions.

Richard


--- xc/programs/Xserver/hw/xfree86/loader/elfloader.c.orig 
2004-12-02 22:29:26.0 +
+++ xc/programs/Xserver/hw/xfree86/loader/elfloader.c   2004-12-02
22:38:37.0 +
@@ -2937,7 +2937,7 @@
ErrorF( "Unable to allocate ELF sections\n" );
return NULL;
 }
-#  if defined(linux) && defined(__ia64__) || defined(__OpenBSD__)
+#  if defined(linux) || defined(__OpenBSD__)
 {
unsigned long page_size = getpagesize();
unsigned long round;




-- 
[EMAIL PROTECTED]



debian on a sun enterprise 250

2004-12-02 Thread james derry
Title: debian on a sun enterprise 250






i've already posted this on debian-user@lists.debian.org and was advised to post it here. please forgive duplication, if you've already received this message.

i've recently taken over sysadmin duties for a sun enterprise 250 running debian. the 250's has frontpanels LEDs, and one on this machine, the general fault LED, burns constant yellow. online documentation for the hardware at http://sunsolve.sun.com/handbook_pub/General/LEDs/E250_LEDs.html says:

This yellow LED blinks slowly while the system runs its power-on self-test (POST) diagnostics and blinks rapidly during OpenBoot diagnostic (OBDiag) tests. It lights steadily when any fault is detected (including a fault also reported by any other LED).

Q: could this be a normal state for enterprise 250s running debian? or is the LED truly reporting that a fault has been detected?

thanks,
james






Re: X11 crashing on 2.4.28

2004-12-02 Thread jurij
[Sorry for breaking the thread and possible line-wrapping]

Ron Murray wrote:

>Richard, does this look likely? Are there any other places that
> could stuff up the exec bit?
>
>  .Ron

Actually, there is one place. The following change has been introduced
when going from 2.4.27 to 2.4.28:

diff -aur linux-2.4.27/arch/sparc64/kernel/itlb_base.S
linux-2.4.28/arch/sparc64/kernel/itlb_base.S
--- linux-2.4.27/arch/sparc64/kernel/itlb_base.S2003-06-13
10:51:32.0 -0400
+++ linux-2.4.28/arch/sparc64/kernel/itlb_base.S2004-11-17
06:54:21.0 -0500
@@ -41,6 +41,9 @@
CREATE_VPTE_OFFSET2(%g4, %g6)   ! Create VPTE offset
ldxa[%g3 + %g6] ASI_P, %g5  ! Load VPTE
 1: brgez,pn%g5, 3f ! Not valid, branch out
+sethi  %hi(_PAGE_EXEC), %g4! Delay-slot
+   andcc   %g5, %g4, %g0   ! Executable?
+   be,pn   %xcc, 3f! Nope, branch.
 nop! Delay-slot
 2: stxa%g5, [%g0] ASI_ITLB_DATA_IN ! Load PTE into TLB
retry   ! Trap return
@@ -73,9 +76,6 @@
nop
nop
nop
-   nop
-   nop
-   nop
CREATE_VPTE_NOP

 #undef CREATE_VPTE_OFFSET1

Since it is sparc64-specific and has to do with EXEC checking, it might
be worth trying to rebuild the 2.4.28 kernel with this change reverted
and see if it helps.

Best regards,

Jurij Smakov
http://www.wooyd.org/pgpkey/



Re: X11 crashing on 2.4.28

2004-12-02 Thread Ron Murray
At Thu, 02 Dec 2004 13:45:59 -0500,
Ron Murray wrote:

> > Anyone fancy compiling a new xserver binary?
> > 
> 
>I'll set one going before I leave work this afternoon. Should have
> completed by tomorrow morning.
> 

   We have a minor problem. Richard's patch seems to refer to a
pristine xfree86-4.3.0 source. When I came to check the patch location
on a build tree that had had the Debian patches applied, I found it to
be quite different. Specifically, the line Richard wanted to change
was now

#   if defined(linux) || defined(__OpenBSD__)

instead of 

#   if defined(linux) && defined(__ia64__) || defined(__OpenBSD__)

   Clearly, there's a Debian patch involved here. I found it at
debian/patches/071_nonexecutable_malloced_mem.diff

and it goes:

> $Id: 071_nonexecutable_malloced_mem.diff 1044 2004-02-16 17:40:33Z branden $
> 
> This patch fixes the assumption that data returned by malloc() is
> executable.  In upstream revision 1.43, the assumption was fixed for
> ia64 only.  We understand it is Linus' position that programs that
> assume data to be executable are broken, so we enable this code for
> all Linux platforms.
> 
> Original patch (before upstream applied its own version) was by David
> Mosberger.
> diff -urN xc/programs/Xserver/hw/xfree86/loader/elfloader.c
> xc.new/programs/Xserver/hw/xfree86/loader/elfloader.c
> --- xc/programs/Xserver/hw/xfree86/loader/elfloader.c   2004-02-07
> 17:33:29.0 -0500
> +++ xc.new/programs/Xserver/hw/xfree86/loader/elfloader.c
> 2004-02-07 17:29:03.0 -0500
> @@ -957,7 +957,7 @@
> ErrorF( "ELFCreateGOT() Unable to reallocate memory\n"
> );
> return FALSE;
> }
> -#   if defined(linux) && defined(__ia64__) || defined(__OpenBSD__)
> +#   if defined(linux) || defined(__OpenBSD__)
> {   
> unsigned long page_size = getpagesize();
> unsigned long round;

   ... which would indicate that Richard's suggestion is already in
the current Debian package. I'd made a build log when I built the
package here, and I have

> Applying patch debian/patches/071_nonexecutable_malloced_mem.diff ... 
> successful.

   in it, so I'm sure it's in the build. 

   Richard, does this look likely? Are there any other places that
could stuff up the exec bit?

 .Ron

--
Ron Murray   ([EMAIL PROTECTED])
http://www.rjmx.net/~ron
GPG Public Key Fingerprint: F2C1 FC47 5EF7 0317 133C  D66B 8ADA A3C4 D86C 74DE



Re: X11 crashing on 2.4.28

2004-12-02 Thread Ron Murray
At Thu, 02 Dec 2004 17:02:58 +,
Richard Mortimer <[EMAIL PROTECTED]> wrote:
> 
> Ok, I think that I've found the problem. The XFree86 binary does its own
> object loading and on sparc it is failing to set the PROT_EXEC bit when
> mapping executable code. This is falling over a change in the kernel
> which checks the executable bit and gives a Segmentation Fault.
> 
> Full rationale, explanation and proposed patch below.

...

   Wow. Well done! That's certainly consistent with what I see.

> 
> Anyone fancy compiling a new xserver binary?
> 

   I'll set one going before I leave work this afternoon. Should have
completed by tomorrow morning.

 .Ron

--
Ron Murray   ([EMAIL PROTECTED])
http://www.rjmx.net/~ron
GPG Public Key Fingerprint: F2C1 FC47 5EF7 0317 133C  D66B 8ADA A3C4 D86C 74DE



Re: XFree crashing on kernel 2.4.28

2004-12-02 Thread Ron Murray
At Thu, 2 Dec 2004 18:06:28 +0100,
Admar Schoonen <[EMAIL PROTECTED]> wrote:
> 
> On Thu, Dec 02, 2004 at 10:44:07AM -0500, Jurij Smakov wrote:
> > Can those who experienced 
> > the crashes please post the contents of their /proc/bus/pci directory? If 
> > it looks like this:
> > 
> > $ ls /proc/bus/pci/
> > 40/  60/  80/  81/  devices
> 
> My affected sun blade 100 looks quite different:
> $ ls /proc/bus/pci/
> :00  :01  devices
> 
> I don't have access to my non affected ultra 5 atm, so I can't check that one.
> 
> The sun blade 100 runs linux 2.6.9 btw.

   Yes, 2.6 kernels do it differently. Mine looks like:

total 0
dr-xr-xr-x  5 root root 0 Dec  2 11:42 ./
dr-xr-xr-x  5 root root 0 Dec  2 11:42 ../
dr-xr-xr-x  2 root root 0 Dec  2 11:42 :80/
dr-xr-xr-x  2 root root 0 Dec  2 11:42 :81/
dr-xr-xr-x  2 root root 0 Dec  2 11:42 0001:00/
-r--r--r--  1 root root 0 Dec  2 11:42 devices

 .Ron

--
Ron Murray   ([EMAIL PROTECTED])
http://www.rjmx.net/~ron
GPG Public Key Fingerprint: F2C1 FC47 5EF7 0317 133C  D66B 8ADA A3C4 D86C 74DE



Re: XFree crashing on kernel 2.4.28

2004-12-02 Thread Admar Schoonen
On Thu, Dec 02, 2004 at 10:44:07AM -0500, Jurij Smakov wrote:
> Can those who experienced 
> the crashes please post the contents of their /proc/bus/pci directory? If 
> it looks like this:
> 
> $ ls /proc/bus/pci/
> 40/  60/  80/  81/  devices

My affected sun blade 100 looks quite different:
$ ls /proc/bus/pci/
:00  :01  devices

I don't have access to my non affected ultra 5 atm, so I can't check that one.

The sun blade 100 runs linux 2.6.9 btw.

Admar



Re: X11 crashing on 2.4.28

2004-12-02 Thread Richard Mortimer
Ok, I think that I've found the problem. The XFree86 binary does its own
object loading and on sparc it is failing to set the PROT_EXEC bit when
mapping executable code. This is falling over a change in the kernel
which checks the executable bit and gives a Segmentation Fault.

Full rationale, explanation and proposed patch below.

Richard

I was looking through the changes between 2.4.27 and 2.4.28 and there is
a patch that adds a check that executed code is actually mapped as
executable (one bit of it is)

diff -urN linux-2.4.27/arch/sparc64/mm/fault.c
linux-2.4.28/arch/sparc64/mm/fault.c
--- linux-2.4.27/arch/sparc64/mm/fault.c2004-08-07
16:26:04.0 -0700
+++ linux-2.4.28/arch/sparc64/mm/fault.c2004-11-17
03:54:21.156379721 -0800

@@ -404,6 +404,16 @@
 */
 good_area:
si_code = SEGV_ACCERR;
+
+   /* If we took a ITLB miss on a non-executable page, catch
+* that here.
+*/
+   if ((fault_code & FAULT_CODE_ITLB) && !(vma->vm_flags &
VM_EXEC)) {
+   BUG_ON(address != regs->tpc);
+   BUG_ON(regs->tstate & TSTATE_PRIV);
+   goto bad_area;
+   }
+
if (fault_code & FAULT_CODE_WRITE) {
if (!(vma->vm_flags & VM_WRITE))
goto bad_area;

Now given that this reports a SIGSEGV if you hit this issue (see
SEGV_ACCERR at the top of the patch) I figured that this would be
something that could be triggered.

Now looking at the broken strace from 2.4.28 we see two mmaps during the
loading of module pcidata. These correspond to the text(code) and data
sections of the binary.

mmap(NULL, 163840, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1,
0) = 0x70272000
lseek(5, 229836, SEEK_SET)  = 229836
read(5, "\0pci_vendor_003d\0pci_vendor_0e11"..., 157024) = 157024
brk(0)  = 0x274000
brk(0x296000)   = 0x296000
mmap(NULL, 139264, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1,
0) = 0x7029a000
lseek(5, 380, SEEK_SET) = 380
read(5, "\201\303\340\10\220\20 \1\201\303\340\10\1\0\0\0\235\343"...,
1612) = 1612

Note that neither has PROT_EXEC set in the mmap. The second one is the
text section that really needs it.

Now looking at the XFree86 code in
xc/programs/Xserver/hw/xfree86/loader/elfloader.c

This gets memory for the data in one of two ways (chosen at compile
time):

xf86loadermalloc - actually a call to the glibc2 malloc
or
mmap.

The mmap specifies PROT_EXEC but I've disassembled the XFree86 binary
and it seems to use the xf86loadermalloc option.

   77514:   90 00 40 08 add  %g1, %o0, %o0
   77518:   40 05 69 49 call  0x1d1a3c
   7751c:   d0 24 60 48 st  %o0, [ %l1 + 0x48 ]
   77520:   84 10 00 08 mov  %o0, %g2
   77524:   80 a2 20 00 cmp  %o0, 0
   77528:   02 80 00 77 be  0x77704

Apologies to those who don't read SPARC assembler!

The call at 77518 is a call to malloc (from the symbol table)

001d1a3c  DF *UND*  0234  GLIBC_2.0   malloc

I'm guessing that malloc doesn't set PROT_EXEC (people generally don't
want it and it would create a security risk).

Now in the elfloader.c file there is a bit of conditional code for ia64
and OpenBSD that does an mprotect to add PROT_EXEC to the code.

So it looks quite clear to me that we need to do the same for sparc.
i.e. apply the following patch (untested I'm afraid)

--- xc/programs/Xserver/hw/xfree86/loader/elfloader.c.orig 
2004-12-02 16:56:31.0 +
+++ xc/programs/Xserver/hw/xfree86/loader/elfloader.c   2004-12-02
16:57:42.0 +
@@ -893,7 +893,7 @@
ErrorF( "ELFCreateGOT() Unable to reallocate memory\n"
);
return FALSE;
}
-#   if defined(linux) && defined(__ia64__) || defined(__OpenBSD__)
+#   if defined(linux) && (defined(__ia64__) || defined(__sparc__)) ||
defined(__OpenBSD__)
{
unsigned long page_size = getpagesize();
unsigned long round;

Anyone fancy compiling a new xserver binary?



On Thu, 2004-12-02 at 06:23, Jurzitza, Dieter wrote:
> Dear listmembers,
> I can confirm for my U60 that the XFree86-debug server comes up on 2.4.28. So 
> I seem to be consistent with what Admar said and what Ron has been saying. 
> What makes me wonder, though, is why does the binary loader work with 2.4.27 
> and does not work with 2.4.28.
> And, moreover, if it is a loader issue it seems more plausible to me that I 
> can observe additional side effects on 2.4.28 not being related to X11 (like 
> very long reaction times on ping / ssh requests, not settling a network 
> connection for quite a while)
> A propably dumb question:
> is that binary loader a simple file? would it be possible to get that loader 
> from another version (like Debian Woody), or is it buried deep down in the 
> kernel?
> Thank you for your inputs,
> take care
> 
> 
> 
> Dieter Jurzitza

-- 
[EMAIL PROTECTED]



RE: XFree crashing on kernel 2.4.28

2004-12-02 Thread Jurzitza, Dieter
Hi Jurij,
I loved your idea :-). However, I do have a bus 00. We have to search for 
something else. See files attached, one from kernel 2.4.26, one from kernel 
2.4.28 / U60 / SMP / 512M. They are identical, and I do have a bus 0.
Thanks for your inputs,
take care



Dieter


-Original Message-
From: Jurij Smakov [mailto:[EMAIL PROTECTED]
Sent: Thursday, December 02, 2004 4:44 PM



***
Diese E-Mail enthaelt vertrauliche und/oder rechtlich geschuetzte 
Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail 
irrtuemlich erhalten haben, informieren Sie bitte sofort den Absender und 
loeschen Sie diese Mail. Das unerlaubte Kopieren sowie die unbefugte Weitergabe 
dieser Mail ist nicht gestattet.
 
This e-mail may contain confidential and/or privileged information. If you are 
not the intended recipient (or have received this e-mail in error) please 
notify the sender immediately and delete this e-mail. Any unauthorized copying, 
disclosure or distribution of the contents in this e-mail is strictly forbidden.
***



ls_proc_bus_devices_2.4.26
Description: ls_proc_bus_devices_2.4.26


ls_proc_bus_devices_2.4.28
Description: ls_proc_bus_devices_2.4.28


Re: fet FTBFS on sparc

2004-12-02 Thread Jurij Smakov

On Thu, 2 Dec 2004, Radu Spineanu wrote:


Hello

Could someone please give me a hint on how to fix this ?


For the record, this problem has already been reported as bug #268450.

Best regards,

Jurij Smakov[EMAIL PROTECTED]
Key: http://www.wooyd.org/pgpkey/   KeyID: C99E03CC



Re: XFree crashing on kernel 2.4.28

2004-12-02 Thread Jurij Smakov

On Wed, 1 Dec 2004, Ron Murray wrote:

  Colour me doubtful about this as a fix. Its bug report has an XFree86.log 
that actually appears to scan the PCI bus, then does lots of other things 
before reporting "no screens found". In contrast, both the logs from the 
originator of this thread and the XFree86.log in bug #280384 show the crash 
occurring immediately after loading the pcidata module, with no attempt to 
scan the PCI bus. That is also my experience, as evidenced by the log in my 
own post to bug #280384. They don't look like the same problem to me at all.


Hi,

I have looked more carefully at bug 279436. The fix which Branden Robinson 
referred to was supposed to take care of the problem on sparc64 when the 
machine does not have a PCI bus numbered zero. Can those who experienced 
the crashes please post the contents of their /proc/bus/pci directory? If 
it looks like this:


$ ls /proc/bus/pci/
40/  60/  80/  81/  devices

i.e. there is no '00' entry, then there is hope, that the patch will 
actually do something useful. If there is a '00' entry, then we are 
looking at a completely different problem.


Best regards,

Jurij Smakov[EMAIL PROTECTED]
Key: http://www.wooyd.org/pgpkey/   KeyID: C99E03CC



X11 crashing on 2.4.28

2004-12-02 Thread Jurzitza, Dieter
Dear listmembers,
I can confirm for my U60 that the XFree86-debug server comes up on 2.4.28. So I 
seem to be consistent with what Admar said and what Ron has been saying. What 
makes me wonder, though, is why does the binary loader work with 2.4.27 and 
does not work with 2.4.28.
And, moreover, if it is a loader issue it seems more plausible to me that I can 
observe additional side effects on 2.4.28 not being related to X11 (like very 
long reaction times on ping / ssh requests, not settling a network connection 
for quite a while)
A propably dumb question:
is that binary loader a simple file? would it be possible to get that loader 
from another version (like Debian Woody), or is it buried deep down in the 
kernel?
Thank you for your inputs,
take care



Dieter Jurzitza


-- 


HARMAN BECKER AUTOMOTIVE SYSTEMS

Dr.-Ing. Dieter Jurzitza
Manager Hardware Systems
   System Development

Industriegebiet Ittersbach
Becker-Göring Str. 16
D-76307 Karlsbad / Germany

Phone: +49 (0)7248 71-1577
Fax:   +49 (0)7248 71-1216
eMail: [EMAIL PROTECTED]
Internet: http://www.becker.de
 


***
Diese E-Mail enthaelt vertrauliche und/oder rechtlich geschuetzte 
Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail 
irrtuemlich erhalten haben, informieren Sie bitte sofort den Absender und 
loeschen Sie diese Mail. Das unerlaubte Kopieren sowie die unbefugte Weitergabe 
dieser Mail ist nicht gestattet.
 
This e-mail may contain confidential and/or privileged information. If you are 
not the intended recipient (or have received this e-mail in error) please 
notify the sender immediately and delete this e-mail. Any unauthorized copying, 
disclosure or distribution of the contents in this e-mail is strictly forbidden.
***