Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755337AbYJHQWa (ORCPT ); Wed, 8 Oct 2008 12:22:30 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1754463AbYJHQWO (ORCPT ); Wed, 8 Oct 2008 12:22:14 -0400 Received: from mail-gx0-f16.google.com ([209.85.217.16]:46581 "EHLO mail-gx0-f16.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754435AbYJHQWL (ORCPT ); Wed, 8 Oct 2008 12:22:11 -0400 DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=gamma; h=message-id:date:from:reply-to:to:subject:cc:in-reply-to :mime-version:content-type:content-transfer-encoding :content-disposition:references; b=FdEPCZbhkD0Lb6FSb82C1PtHee1ncHk/XlodUWzM+s3ZOv0iJ4dfRIq7bY9y4EtBVR OfeHgarWbfQWzorZgtpK6CMBgJ8zHZgqqKSIpV1JSBqXAIydmuMFE76aEYsxWaKSa9PW OdlekR5MDcr6sbRWmko8YwLLljA434P/dYgKw= Message-ID: <9ea470500810080922x326821c5p47053afa7a1d261e@mail.gmail.com> Date: Wed, 8 Oct 2008 18:22:10 +0200 From: "Boris Petkov" Reply-To: petkovbb@gmail.com To: "Mark de Wever" Subject: Re: [patch][repost] ide-tape build fix Cc: "Bartlomiej Zolnierkiewicz" , "Sergei Shtylyov" , "Gadi Oxman" , linux-ide@vger.kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <20081008154552.GA3907@localhost> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <48D79ABD.8060805@ru.mvista.com> <20080922204129.GA3495@localhost> <48D80949.4080901@ru.mvista.com> <20080923074845.GB5656@gollum.tnic> <20080923165914.GA7803@localhost> <9ea470500809231011p5ea37fc4u71eeeddf6ccec45a@mail.gmail.com> <20080923212018.GA3348@localhost> <20081007182615.GA2400@localhost> <20081008063352.GA13530@gollum.tnic> <20081008154552.GA3907@localhost> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2322 Lines: 67 On Wed, Oct 8, 2008 at 5:45 PM, Mark de Wever wrote: > On Wed, Oct 08, 2008 at 08:33:52AM +0200, Borislav Petkov wrote: > Hi, >> Bugger, I should be getting at least warnings when compiling this but I don't. >> This is because I don't have CONFIG_LBD enabled. However, the %ld and %d >> format specifiers are also not entirely correct but gcc doesn't warn about them >> - I guess it checks only size but not signedness... > > I guess so too. > >> Would you like to redo your patch and add a proper comment ontop? > > Here you go. > > @Boris do you want to add your Signed-off-by too? no, just Acked-by: Borislav Petkov > @Bart please apply this patch. > > -- > Subject: ide-tape: Buildfix when IDETAPE_DEBUG_LOG is set to 1. > > The format specifier for rq->sector didn't specify the proper size and > signedness. Borislav Petkov discovered that the signedness for > rq->nr_sectors and rq->current_nr_sectors also were incorrect. > > Signed-off-by: Mark de Wever > --- > drivers/ide/ide-tape.c | 7 ++++--- > 1 files changed, 4 insertions(+), 3 deletions(-) > > diff --git a/drivers/ide/ide-tape.c b/drivers/ide/ide-tape.c > index 3833189..3d5f782 100644 > --- a/drivers/ide/ide-tape.c > +++ b/drivers/ide/ide-tape.c > @@ -978,9 +978,10 @@ static ide_startstop_t idetape_do_request(ide_drive_t *drive, > struct request *postponed_rq = tape->postponed_rq; > u8 stat; > > - debug_log(DBG_SENSE, "sector: %ld, nr_sectors: %ld," > - " current_nr_sectors: %d\n", > - rq->sector, rq->nr_sectors, rq->current_nr_sectors); > + debug_log(DBG_SENSE, "sector: %llu, nr_sectors: %lu," > + " current_nr_sectors: %u\n", > + (unsigned long long)rq->sector, rq->nr_sectors, > + rq->current_nr_sectors); > > if (!blk_special_request(rq)) { > /* We do not support buffer cache originated requests. */ > -- > 1.5.6.5 > > Regards, > Mark de Wever > -- Regards/Gruss, Boris -- 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/