login
Login
/
Register
Search
Forums
News
Blogs
Features
Site
Home
»
Mailing list archives
»
linux-kernel
»
2008
»
June
»
26
Re: Oops when using growisofs
view
thread
!MAILaRCHIVE_VOTE_RePLACE
Previous message: [
thread
] [
date
] [
author
]
Next message: [thread] [
date
] [
author
]
[view in full thread]
From:
Jens Axboe <jens.axboe@...>
To: Michael Buesch <mb@...>
Cc: Jan Kara <jack@...>, Andrew Morton <akpm@...>, Arnd Bergmann <arnd@...>, linux-kernel <linux-kernel@...>
Subject:
Re: Oops when using growisofs
Date: Thursday, June 26, 2008 - 2:41 pm
On Thu, Jun 26 2008, Michael Buesch wrote:
quoted text
> On Thursday 26 June 2008 20:36:11 Jens Axboe wrote: > > Something like this, totally untested... > > > > diff --git a/drivers/ide/ide-cd.c b/drivers/ide/ide-cd.c > > index 68e7f19..5c1e663 100644 > > --- a/drivers/ide/ide-cd.c > > +++ b/drivers/ide/ide-cd.c > > @@ -1308,13 +1308,29 @@ static int cdrom_read_capacity(ide_drive_t *drive, unsigned long *capacity, > > req.cmd_flags |= REQ_QUIET; > > > > stat = ide_cd_queue_pc(drive, &req); > > - if (stat == 0) { > > - *capacity = 1 + be32_to_cpu(capbuf.lba); > > - *sectors_per_frame = > > - be32_to_cpu(capbuf.blocklen) >> SECTOR_BITS; > > + if (stat) > > + return stat; > > + > > + /* > > + * Sanity check the given block size > > + */ > > + switch (capbuf.blocklen) { > > + case 512: > > + case 1024: > > + case 2048: > > + case 4096: > > + break; > > + default: > > + printk(KERN_ERR "ide-cd: weird block size %u\n", > > + capbuf.blocklen); > > + printk(KERN_ERR "ide-cd: default to 2kb block size\n"); > > KERN_WARNING
It's pretty serious, so...
quoted text
> > + capbuf.blocklen = 2048; > > + break; > > } > > > > - return stat; > > + *capacity = 1 + be32_to_cpu(capbuf.lba); > > + *sectors_per_frame = be32_to_cpu(capbuf.blocklen) >> SECTOR_BITS; > > + return 0; > > } > > > > static int cdrom_read_tocentry(ide_drive_t *drive, int trackno, int msf_flag, > > > > I'll test this. Thanks a lot. :) > However I cannot reproduce the bug. So I cannot tell whether it fixes it.
The patch wont hurt, probably we should just add it just in case. -- Jens Axboe --
unsubscribe notice
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to
majordomo@vger.kernel.org
More majordomo info at
http://vger.kernel.org/majordomo-info.html
Please read the FAQ at
http://www.tux.org/lkml/
Previous message: [
thread
] [
date
] [
author
]
Next message: [thread] [
date
] [
author
]
Messages in current thread:
Oops when using growisofs
, Michael Buesch
, (Sun Jun 22, 12:18 pm)
Re: Oops when using growisofs
, Arnd Bergmann
, (Sun Jun 22, 5:22 pm)
Re: Oops when using growisofs
, Michael Buesch
, (Sun Jun 22, 6:05 pm)
Re: Oops when using growisofs
, Michael Buesch
, (Sun Jun 22, 6:28 pm)
Re: Oops when using growisofs
, Andrew Morton
, (Mon Jun 23, 2:34 am)
Re: Oops when using growisofs
, Jan Kara
, (Tue Jun 24, 1:28 pm)
Re: Oops when using growisofs
, Michael Buesch
, (Tue Jun 24, 2:39 pm)
Re: Oops when using growisofs
, Jan Kara
, (Wed Jun 25, 5:37 am)
Re: Oops when using growisofs
, Michael Buesch
, (Wed Jun 25, 5:46 am)
Re: Oops when using growisofs
, Jan Kara
, (Thu Jun 26, 1:05 pm)
Re: Oops when using growisofs
, Jens Axboe
, (Thu Jun 26, 2:11 pm)
Re: Oops when using growisofs
, Michael Buesch
, (Thu Jun 26, 2:21 pm)
Re: Oops when using growisofs
, Jens Axboe
, (Thu Jun 26, 2:36 pm)
Re: Oops when using growisofs
, Andrew Morton
, (Tue Jul 22, 5:25 am)
Re: Oops when using growisofs
, Jan Kara
, (Wed Jul 9, 2:46 pm)
Re: Oops when using growisofs
, Michael Buesch
, (Sun Jun 29, 3:39 pm)
Re: Oops when using growisofs
, Michael Buesch
, (Thu Jun 26, 2:39 pm)
Re: Oops when using growisofs
, Jens Axboe
, (Thu Jun 26, 2:41 pm)
Re: Oops when using growisofs
, Arnd Bergmann
, (Tue Jun 24, 9:42 pm)
Re: Oops when using growisofs
, Nick Piggin
, (Mon Jun 23, 2:59 am)
Re: Oops when using growisofs
, Arnd Bergmann
, (Sun Jun 22, 5:31 pm)
Re: Oops when using growisofs
, Michael Buesch
, (Sun Jun 22, 6:09 pm)
Navigation
Create content
Mailing list archives
Recent posts
Popular discussions
linux-kernel
:
Tarkan Erimer
Re: Dual-Licensing Linux Kernel with GPL V2 and GPL V3
Greg Kroah-Hartman
[PATCH 004/196] Chinese: add translation of SubmittingPatches
Artem Bityutskiy
[PATCH 18/44 take 2] [UBI] build unit implementation
James Morris
Re: LSM conversion to static interface
git
:
linux-netdev
:
Paul Jackson
[PATCH] cpuset sched_load_balance kmalloc fix
Gerrit Renker
[PATCH 15/37] dccp: Set per-connection CCIDs via socket options
Jarek Poplawski
[PATCH] pkt_sched: Destroy gen estimators under rtnl_lock().
Linus Torvalds
Re: [GIT]: Networking
openbsd-misc
:
Colocation donated by:
Who's online
There are currently
1 user
and
483 guests
online.
Online users
sellhousefast
Syndicate