The change that went into 2.5.69 for DAC960 seems to break it here.
(http://marc.theaimsgroup.com/?l=linux-kernel&m=105209603501299&w=2)
I backed out the last two changesets in DAC960.c, and the driver runs
again. Backing out only:
ChangeSet 1.1132 2003/05/15 09:01:05 [email protected]
[PATCH] DAC960 typedef cleanup patch
Did not resolve the panic, however backing out:
ChangeSet 1.1042.94.9 2003/04/30 07:31:56 [email protected]
[PATCH] DAC960 patch to entry points with a new fix
Seems to resolve the problem.
The problem was, (copied by hand, please let me know if I've omitted a
critical field.):
kernel NULL pointer deref - virt 00000019
Oops: 0000 [#1]
CPU: 0
EIP: 0060:[<c02774d3>] Not tainted
EFLAGS: 00010286
EIP is at DAC960_ioctl+0x33/0x190
Process swapper (pid: 1, ...)
Call Trace:
] blkdev_ioctl+0xa5/0x466
] ioctl_by_dev+0x41/0x50
] isofs_get_last_session+0xb4/0xe0
] set_blocksize+
] sb_set_blocksize+
] isofs_fill_super+
] sb_set_blocksize+
] get_sb_bdev+
] isofs_get_sb+
] isofs_fill_super+
] do_kern_mount+
] do_add_mount+
] do_mount+
] copy_mount_options+
] sys_mount+
] do_mount_root+
] mount_block_root+
] mount_root+
] prepare_namespace+
] init_workqueues+
] init+0x5f/0x200
] init+0x0/0x200
] kernel_thread_helper+0x5/0x10
Code: f6 43 19 08 0f 85 33 01 00 00 81 ff 01 03 00 00 74 12 ba ea
<0>kernel panic: Attempted to kill init!
This is on a SuSE 8.1, dual Athlon MP system, gcc 3.2, binutils
2.12.90.0.15-40. Please let me know if additional detail is helpful.
--
Kevin
Kevin Brosius <[email protected]> wrote:
>
> kernel NULL pointer deref - virt 00000019
> Oops: 0000 [#1]
> CPU: 0
> EIP: 0060:[<c02774d3>] Not tainted
> EFLAGS: 00010286
> EIP is at DAC960_ioctl+0x33/0x190
>
> Process swapper (pid: 1, ...)
>
> Call Trace:
> ] blkdev_ioctl+0xa5/0x466
> ] ioctl_by_dev+0x41/0x50
You tricking me. That's "ioctl_by_bdev". It passes in a null file*, and
we have to handle it.
Does this fix?
diff -puN drivers/block/DAC960.c~DAC960-oops-fix drivers/block/DAC960.c
--- 25/drivers/block/DAC960.c~DAC960-oops-fix 2003-05-16 20:44:52.000000000 -0700
+++ 25-akpm/drivers/block/DAC960.c 2003-05-16 20:45:16.000000000 -0700
@@ -102,7 +102,7 @@ static int DAC960_ioctl(struct inode *in
int drive_nr = (int)disk->private_data;
struct hd_geometry g, *loc = (struct hd_geometry *)arg;
- if (file->f_flags & O_NONBLOCK)
+ if (file && file->f_flags & O_NONBLOCK)
return DAC960_UserIOCTL(inode, file, cmd, arg);
if (cmd != HDIO_GETGEO || !loc)
_
Andrew Morton wrote:
>
>
> Kevin Brosius <[email protected]> wrote:
> >
> > kernel NULL pointer deref - virt 00000019
> > Oops: 0000 [#1]
> > CPU: 0
> > EIP: 0060:[<c02774d3>] Not tainted
> > EFLAGS: 00010286
> > EIP is at DAC960_ioctl+0x33/0x190
> >
> > Process swapper (pid: 1, ...)
> >
> > Call Trace:
> > ] blkdev_ioctl+0xa5/0x466
> > ] ioctl_by_dev+0x41/0x50
>
> You tricking me. That's "ioctl_by_bdev". It passes in a null file*, and
> we have to handle it.
Yes, sorry. Missed a letter in that typing.
>
> Does this fix?
Yes, works great! No further panic. Thank you.
>
> diff -puN drivers/block/DAC960.c~DAC960-oops-fix drivers/block/DAC960.c
> --- 25/drivers/block/DAC960.c~DAC960-oops-fix 2003-05-16 20:44:52.000000000 -0700
> +++ 25-akpm/drivers/block/DAC960.c 2003-05-16 20:45:16.000000000 -0700
> @@ -102,7 +102,7 @@ static int DAC960_ioctl(struct inode *in
> int drive_nr = (int)disk->private_data;
> struct hd_geometry g, *loc = (struct hd_geometry *)arg;
>
> - if (file->f_flags & O_NONBLOCK)
> + if (file && file->f_flags & O_NONBLOCK)
> return DAC960_UserIOCTL(inode, file, cmd, arg);
>
> if (cmd != HDIO_GETGEO || !loc)
>
> _
--
Kevin
I apologize for missing this before submitting that patch.
I'm working on a patch that eliminates this O_NONBLOCK nonsense entirely.
I'm away from work most of this week though. Back next week.
On Sat, May 17, 2003 at 12:14:06AM -0400, Kevin Brosius wrote:
> Andrew Morton wrote:
> >
> >
> > Kevin Brosius <[email protected]> wrote:
> > >
> > > kernel NULL pointer deref - virt 00000019
> > > Oops: 0000 [#1]
> > > CPU: 0
> > > EIP: 0060:[<c02774d3>] Not tainted
> > > EFLAGS: 00010286
> > > EIP is at DAC960_ioctl+0x33/0x190
> > >
> > > Process swapper (pid: 1, ...)
> > >
> > > Call Trace:
> > > ] blkdev_ioctl+0xa5/0x466
> > > ] ioctl_by_dev+0x41/0x50
> >
> > You tricking me. That's "ioctl_by_bdev". It passes in a null file*, and
> > we have to handle it.
>
> Yes, sorry. Missed a letter in that typing.
>
> >
> > Does this fix?
>
> Yes, works great! No further panic. Thank you.
>
> >
> > diff -puN drivers/block/DAC960.c~DAC960-oops-fix drivers/block/DAC960.c
> > --- 25/drivers/block/DAC960.c~DAC960-oops-fix 2003-05-16 20:44:52.000000000 -0700
> > +++ 25-akpm/drivers/block/DAC960.c 2003-05-16 20:45:16.000000000 -0700
> > @@ -102,7 +102,7 @@ static int DAC960_ioctl(struct inode *in
> > int drive_nr = (int)disk->private_data;
> > struct hd_geometry g, *loc = (struct hd_geometry *)arg;
> >
> > - if (file->f_flags & O_NONBLOCK)
> > + if (file && file->f_flags & O_NONBLOCK)
> > return DAC960_UserIOCTL(inode, file, cmd, arg);
> >
> > if (cmd != HDIO_GETGEO || !loc)
> >
> > _
>
> --
> Kevin
> -
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to [email protected]
> More majordomo info at http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at http://www.tux.org/lkml/