Skip to contentSkip to conversation

JFS on PA-RISC-Linux

parisc-linux Peter Weilbacher 5 participants 8 messages Jul 3, 2001 – Aug 14, 2001 1 message not in the archive

lore
Share & tools
lore
#1 lore raw
In reply to a message not in the archive

Hi!

Did anyone try JFS on other architectures than iX86 (the 1.0.0 announcement did only restrict it to 2.4.X :-) )? I wanted to test on PA-RISC-Linux today, and the patched kernel and the utilities compiled OK (Kernel calls itself 2.4.0-pa49 #1), but when trying to create a JFS partition with mkfs.jfs I either get

mkfs.jfs development version: $Name: v1_0_0 $

Warning! All data on device /dev/sdb1 will be lost!

Continue? (Y/N) Y
|
Bus error

or

mkfs.jfs development version: $Name: v1_0_0 $

Warning! All data on device /dev/sdb1 will be lost!

Continue? (Y/N) Y
<4>mkfs.jfs(379): unaligned access to 0x00035245 at ip=0x000137af Not-handled unaligned insn 0x4a740108
Unaligned handler failed, ret = -1

(optionally without <4> or with Bus error)

Is it JFS's fault or that of the PA-RISC-Linux port? The messages do not seem to be from mkfs.jfs, as I did not find anything like that in its source. Is it too early to try things like this?

Peter.

#2 lore raw
Quoted 9 lines · Peter Weilbacher
	<4>mkfs.jfs(379): unaligned access to 0x00035245 at ip=0x000137af
	Not-handled unaligned insn 0x4a740108
	Unaligned handler failed, ret = -1

(optionally without <4> or with Bus error)

Is it JFS's fault or that of the PA-RISC-Linux port? The messages do not seem to be from mkfs.jfs, as I did not find anything like that in its source. Is it too early to try things like this?

It's the fault of both, really. The userspace program is attempting to do an unaligned access. say, loading an int from a non-word-aligned address. Most CPUs can't handle this and take a fault. We haven't yet implemented a trap handler for that fault.

Or rather, tausq has implemented one, but hasn't activated it yet, I believe.... tausq?

Signature · 1 line
Revolutions do not require corporate support.
#4 lore raw
In reply to Peter Weilbacher

Peter Weilbacher wrote:
...
I can't comment on the bus error.

Quoted 4 lines

mkfs.jfs development version: $Name: v1_0_0 $

Warning! All data on device /dev/sdb1 will be lost!

Quoted 8 lines

Continue? (Y/N) Y
<4>mkfs.jfs(379): unaligned access to 0x00035245 at ip=0x000137af Not-handled unaligned insn 0x4a740108
Unaligned handler failed, ret = -1

(optionally without <4> or with Bus error)

Is it JFS's fault or that of the PA-RISC-Linux port?

The parisc-linux port. Randolph Chung recently added support for unaligned access emulation. Randolph needs more info to fix this problem. See http://lists.parisc-linux.org/pipermail/parisc-linux/2001-June/012946.html

Quoted 3 lines

The messages do
not seem to be from mkfs.jfs, as I did not find anything like that in its source. Is it too early to try things like this?

No. If no one tries, we won't know what's broken. The basic stuff works.

thanks,
grant

Grant Grundler
parisc-linux {PCI|IOMMU|SMP} hacker
+1.408.447.7253

#5 lore raw
In reply to Peter Weilbacher

Please do not cc closed (moderated) lists and lists at parisc-linux.org. Failure to follow this friendly warning may result in offenders being barred from lists on this server. Thanks.

Signature · 1 line
Revolutions do not require corporate support.
#3 lore raw
In reply to Matthew Wilcox
Quoted 7 lines

It's the fault of both, really. The userspace program is attempting to do an unaligned access. say, loading an int from a non-word-aligned address. Most CPUs can't handle this and take a fault. We haven't yet implemented a trap handler for that fault.

Or rather, tausq has implemented one, but hasn't activated it yet, I believe.... tausq?

The trap handler is activated but doesn't handle this particular load instruction yet. I'll fix this tomorrow.

randolph

Signature · 2 lines
Debian Developer <[email protected]>
http://www.TauSq.org/
#6 lore raw

[parisc-linux] Once more: JFS

In reply to Peter Weilbacher

Hi again,

I gave it a new try with JFS on PA-RISC-Linux. I got kernel 2.4.7-pa2 (linux-20010810.tar.gz) and patched it with JFS 1.0.2. Cross-compiling the kernel went well, but I had to use the native PA-RISC-gcc to compile the utilities.

mkfs.jfs now works ok, as opposed to kernel 2.4.0-pa49, and I can copy files to that partition, but fsck.jfs seems to have problems. When checking on boot the following messages are written to dmesg:

fsck.jfs(34): unaligned access to 0xfaf0050f at ip=0x0002e50b fsck.jfs(34): unaligned access to 0xfaf0050f at ip=0x0002e517 fsck.jfs(34): unaligned access to 0xfaf0050f at ip=0x0002e533 fsck.jfs(34): unaligned access to 0xfaf0050f at ip=0x0002e443 fsck.jfs(34): unaligned access to 0xfaf0050f at ip=0x0002e50b fsck.jfs(34): unaligned access to 0xfaf0050f at ip=0x0002e517 fsck.jfs(34): unaligned access to 0xfaf0050f at ip=0x0002e533 fsck.jfs(34): unaligned access to 0xfaf0050f at ip=0x0002e443 fsck.jfs(34): unaligned access to 0xfaf0058f at ip=0x0002e50b fsck.jfs(34): unaligned access to 0xfaf0058f at ip=0x0002e517 fsck.jfs(34): unaligned access to 0xfaf0058f at ip=0x0002e533 fsck.jfs(34): unaligned access to 0xfaf0058f at ip=0x0002e443 fsck.jfs(34): unaligned access to 0xfaf004cf at ip=0x0002e50b fsck.jfs(34): unaligned access to 0xfaf004cf at ip=0x0002e517 fsck.jfs(34): unaligned access to 0xfaf004cf at ip=0x0002e533 fsck.jfs(34): unaligned access to 0xfaf004cf at ip=0x0002e443 fsck.jfs(34): unaligned access to 0xfaf004cf at ip=0x0002e50b fsck.jfs(34): unaligned access to 0xfaf004cf at ip=0x0002e517 fsck.jfs(34): unaligned access to 0xfaf004cf at ip=0x0002e533 fsck.jfs(34): unaligned access to 0xfaf004cf at ip=0x0002e443 fsck.jfs(34): unaligned access to 0xfaf004cf at ip=0x0002e50b fsck.jfs(34): unaligned access to 0xfaf004cf at ip=0x0002e517 fsck.jfs(34): unaligned access to 0xfaf004cf at ip=0x0002e533 fsck.jfs(34): unaligned access to 0xfaf004cf at ip=0x0002e443

And hundreds more similar errors when doing a manual fsck.jfs are written to kern.log, and this check never finishes...

This time it seems to be a PA-RISC-Linux problem, as I recall earlier problems with "unaligned access" messages.

Greetings,
Peter.

#7 lore raw

Re: [parisc-linux] Once more: JFS

Quoted 5 lines

And hundreds more similar errors when doing a manual fsck.jfs are written to kern.log, and this check never finishes...

This time it seems to be a PA-RISC-Linux problem, as I recall earlier problems with "unaligned access" messages.

The unaligned messages by themselves indicate a *user-space* problem. We can look at the fsck.jfs code and see what it's doing.... my guess is that there's some casting going on that is causing the unaligned accesses. For example, if you had something like this:

char foo[10];
long *bar = (long *)(foo+2);

*bar = 10;

then it will trigger an unaligned access. (usually it's not quite that obvious though)

If you see a "Not-handled unaligned access" message then there's a kernel issue that we need to address, but doesn't seem to be the case here.

Please visit http://bugs.parisc-linux.org/ and follow the instructions to file a bug, and we will look into this.

randolph

Signature · 4 lines
   @..@                                         http://www.TauSq.org/
  (----)
 ( >__< )
 ^^ ~~ ^^
#8 lore raw

Re: [parisc-linux] Once more: JFS

Quoted 3 lines · Randolph Chung

The unaligned messages by themselves indicate a *user-space* problem. We can look at the fsck.jfs code and see what it's doing.... my guess is that there's some casting going on that is causing the unaligned accesses.

[...]

Quoted 2 lines

then it will trigger an unaligned access. (usually it's not quite that obvious though)

I am a bit out of programming, so I reported it to the JFS people, they should be faster at finding this than me.

Quoted 3 lines

If you see a "Not-handled unaligned access" message then there's a kernel issue that we need to address, but doesn't seem to be the case here.

No, none like that. Thanks for the explenation!

Peter.