* [PATCH] n_r3964: drop bogus fmt casts
@ 2005-09-28 23:05 Al Viro
0 siblings, 0 replies; 3+ messages in thread
From: Al Viro @ 2005-09-28 23:05 UTC (permalink / raw)
To: Linus Torvalds; +Cc: Alexey Dobriyan, linux-kernel
From: Alexey Dobriyan <adobriyan@gmail.com>
* print pointers with %p
* casting pointer structure field to int and printing it with %d...
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
----
diff -urN RC14-rc2-git6-ppc-arch/drivers/char/n_r3964.c RC14-rc2-git6-n_r3964/drivers/char/n_r3964.c
--- RC14-rc2-git6-ppc-arch/drivers/char/n_r3964.c 2005-08-28 23:09:41.000000000 -0400
+++ RC14-rc2-git6-n_r3964/drivers/char/n_r3964.c 2005-09-28 13:02:21.000000000 -0400
@@ -229,8 +229,8 @@
TRACE_L("line discipline %d registered", N_R3964);
TRACE_L("flags=%x num=%x", tty_ldisc_N_R3964.flags,
tty_ldisc_N_R3964.num);
- TRACE_L("open=%x", (int)tty_ldisc_N_R3964.open);
- TRACE_L("tty_ldisc_N_R3964 = %x", (int)&tty_ldisc_N_R3964);
+ TRACE_L("open=%p", tty_ldisc_N_R3964.open);
+ TRACE_L("tty_ldisc_N_R3964 = %p", &tty_ldisc_N_R3964);
}
else
{
@@ -267,8 +267,8 @@
spin_unlock_irqrestore(&pInfo->lock, flags);
- TRACE_Q("add_tx_queue %x, length %d, tx_first = %x",
- (int)pHeader, pHeader->length, (int)pInfo->tx_first );
+ TRACE_Q("add_tx_queue %p, length %d, tx_first = %p",
+ pHeader, pHeader->length, pInfo->tx_first );
}
static void remove_from_tx_queue(struct r3964_info *pInfo, int error_code)
@@ -285,10 +285,10 @@
return;
#ifdef DEBUG_QUEUE
- printk("r3964: remove_from_tx_queue: %x, length %d - ",
- (int)pHeader, (int)pHeader->length );
+ printk("r3964: remove_from_tx_queue: %p, length %u - ",
+ pHeader, pHeader->length );
for(pDump=pHeader;pDump;pDump=pDump->next)
- printk("%x ", (int)pDump);
+ printk("%p ", pDump);
printk("\n");
#endif
@@ -319,10 +319,10 @@
spin_unlock_irqrestore(&pInfo->lock, flags);
kfree(pHeader);
- TRACE_M("remove_from_tx_queue - kfree %x",(int)pHeader);
+ TRACE_M("remove_from_tx_queue - kfree %p",pHeader);
- TRACE_Q("remove_from_tx_queue: tx_first = %x, tx_last = %x",
- (int)pInfo->tx_first, (int)pInfo->tx_last );
+ TRACE_Q("remove_from_tx_queue: tx_first = %p, tx_last = %p",
+ pInfo->tx_first, pInfo->tx_last );
}
static void add_rx_queue(struct r3964_info *pInfo, struct r3964_block_header *pHeader)
@@ -346,9 +346,9 @@
spin_unlock_irqrestore(&pInfo->lock, flags);
- TRACE_Q("add_rx_queue: %x, length = %d, rx_first = %x, count = %d",
- (int)pHeader, pHeader->length,
- (int)pInfo->rx_first, pInfo->blocks_in_rx_queue);
+ TRACE_Q("add_rx_queue: %p, length = %d, rx_first = %p, count = %d",
+ pHeader, pHeader->length,
+ pInfo->rx_first, pInfo->blocks_in_rx_queue);
}
static void remove_from_rx_queue(struct r3964_info *pInfo,
@@ -360,10 +360,10 @@
if(pHeader==NULL)
return;
- TRACE_Q("remove_from_rx_queue: rx_first = %x, rx_last = %x, count = %d",
- (int)pInfo->rx_first, (int)pInfo->rx_last, pInfo->blocks_in_rx_queue );
- TRACE_Q("remove_from_rx_queue: %x, length %d",
- (int)pHeader, (int)pHeader->length );
+ TRACE_Q("remove_from_rx_queue: rx_first = %p, rx_last = %p, count = %d",
+ pInfo->rx_first, pInfo->rx_last, pInfo->blocks_in_rx_queue );
+ TRACE_Q("remove_from_rx_queue: %p, length %u",
+ pHeader, pHeader->length );
spin_lock_irqsave(&pInfo->lock, flags);
@@ -401,10 +401,10 @@
spin_unlock_irqrestore(&pInfo->lock, flags);
kfree(pHeader);
- TRACE_M("remove_from_rx_queue - kfree %x",(int)pHeader);
+ TRACE_M("remove_from_rx_queue - kfree %p",pHeader);
- TRACE_Q("remove_from_rx_queue: rx_first = %x, rx_last = %x, count = %d",
- (int)pInfo->rx_first, (int)pInfo->rx_last, pInfo->blocks_in_rx_queue );
+ TRACE_Q("remove_from_rx_queue: rx_first = %p, rx_last = %p, count = %d",
+ pInfo->rx_first, pInfo->rx_last, pInfo->blocks_in_rx_queue );
}
static void put_char(struct r3964_info *pInfo, unsigned char ch)
@@ -506,8 +506,8 @@
if(tty->driver->write_room)
room=tty->driver->write_room(tty);
- TRACE_PS("transmit_block %x, room %d, length %d",
- (int)pBlock, room, pBlock->length);
+ TRACE_PS("transmit_block %p, room %d, length %d",
+ pBlock, room, pBlock->length);
while(pInfo->tx_position < pBlock->length)
{
@@ -588,7 +588,7 @@
/* prepare struct r3964_block_header: */
pBlock = kmalloc(length+sizeof(struct r3964_block_header), GFP_KERNEL);
- TRACE_M("on_receive_block - kmalloc %x",(int)pBlock);
+ TRACE_M("on_receive_block - kmalloc %p",pBlock);
if(pBlock==NULL)
return;
@@ -868,11 +868,11 @@
if(pMsg)
{
kfree(pMsg);
- TRACE_M("enable_signals - msg kfree %x",(int)pMsg);
+ TRACE_M("enable_signals - msg kfree %p",pMsg);
}
}
kfree(pClient);
- TRACE_M("enable_signals - kfree %x",(int)pClient);
+ TRACE_M("enable_signals - kfree %p",pClient);
return 0;
}
}
@@ -890,7 +890,7 @@
{
/* add client to client list */
pClient=kmalloc(sizeof(struct r3964_client_info), GFP_KERNEL);
- TRACE_M("enable_signals - kmalloc %x",(int)pClient);
+ TRACE_M("enable_signals - kmalloc %p",pClient);
if(pClient==NULL)
return -ENOMEM;
@@ -954,7 +954,7 @@
queue_the_message:
pMsg = kmalloc(sizeof(struct r3964_message), GFP_KERNEL);
- TRACE_M("add_msg - kmalloc %x",(int)pMsg);
+ TRACE_M("add_msg - kmalloc %p",pMsg);
if(pMsg==NULL) {
return;
}
@@ -1067,11 +1067,11 @@
struct r3964_info *pInfo;
TRACE_L("open");
- TRACE_L("tty=%x, PID=%d, disc_data=%x",
- (int)tty, current->pid, (int)tty->disc_data);
+ TRACE_L("tty=%p, PID=%d, disc_data=%p",
+ tty, current->pid, tty->disc_data);
pInfo=kmalloc(sizeof(struct r3964_info), GFP_KERNEL);
- TRACE_M("r3964_open - info kmalloc %x",(int)pInfo);
+ TRACE_M("r3964_open - info kmalloc %p",pInfo);
if(!pInfo)
{
@@ -1080,26 +1080,26 @@
}
pInfo->rx_buf = kmalloc(RX_BUF_SIZE, GFP_KERNEL);
- TRACE_M("r3964_open - rx_buf kmalloc %x",(int)pInfo->rx_buf);
+ TRACE_M("r3964_open - rx_buf kmalloc %p",pInfo->rx_buf);
if(!pInfo->rx_buf)
{
printk(KERN_ERR "r3964: failed to alloc receive buffer\n");
kfree(pInfo);
- TRACE_M("r3964_open - info kfree %x",(int)pInfo);
+ TRACE_M("r3964_open - info kfree %p",pInfo);
return -ENOMEM;
}
pInfo->tx_buf = kmalloc(TX_BUF_SIZE, GFP_KERNEL);
- TRACE_M("r3964_open - tx_buf kmalloc %x",(int)pInfo->tx_buf);
+ TRACE_M("r3964_open - tx_buf kmalloc %p",pInfo->tx_buf);
if(!pInfo->tx_buf)
{
printk(KERN_ERR "r3964: failed to alloc transmit buffer\n");
kfree(pInfo->rx_buf);
- TRACE_M("r3964_open - rx_buf kfree %x",(int)pInfo->rx_buf);
+ TRACE_M("r3964_open - rx_buf kfree %p",pInfo->rx_buf);
kfree(pInfo);
- TRACE_M("r3964_open - info kfree %x",(int)pInfo);
+ TRACE_M("r3964_open - info kfree %p",pInfo);
return -ENOMEM;
}
@@ -1154,11 +1154,11 @@
if(pMsg)
{
kfree(pMsg);
- TRACE_M("r3964_close - msg kfree %x",(int)pMsg);
+ TRACE_M("r3964_close - msg kfree %p",pMsg);
}
}
kfree(pClient);
- TRACE_M("r3964_close - client kfree %x",(int)pClient);
+ TRACE_M("r3964_close - client kfree %p",pClient);
pClient=pNext;
}
/* Remove jobs from tx_queue: */
@@ -1177,11 +1177,11 @@
/* Free buffers: */
wake_up_interruptible(&pInfo->read_wait);
kfree(pInfo->rx_buf);
- TRACE_M("r3964_close - rx_buf kfree %x",(int)pInfo->rx_buf);
+ TRACE_M("r3964_close - rx_buf kfree %p",pInfo->rx_buf);
kfree(pInfo->tx_buf);
- TRACE_M("r3964_close - tx_buf kfree %x",(int)pInfo->tx_buf);
+ TRACE_M("r3964_close - tx_buf kfree %p",pInfo->tx_buf);
kfree(pInfo);
- TRACE_M("r3964_close - info kfree %x",(int)pInfo);
+ TRACE_M("r3964_close - info kfree %p",pInfo);
}
static ssize_t r3964_read(struct tty_struct *tty, struct file *file,
@@ -1234,7 +1234,7 @@
count = sizeof(struct r3964_client_message);
kfree(pMsg);
- TRACE_M("r3964_read - msg kfree %x",(int)pMsg);
+ TRACE_M("r3964_read - msg kfree %p",pMsg);
if (copy_to_user(buf,&theMsg, count))
return -EFAULT;
@@ -1279,7 +1279,7 @@
* Allocate a buffer for the data and copy it from the buffer with header prepended
*/
new_data = kmalloc (count+sizeof(struct r3964_block_header), GFP_KERNEL);
- TRACE_M("r3964_write - kmalloc %x",(int)new_data);
+ TRACE_M("r3964_write - kmalloc %p",new_data);
if (new_data == NULL) {
if (pInfo->flags & R3964_DEBUG)
{
^ permalink raw reply [flat|nested] 3+ messages in thread* [PATCHSET] 2.6.13-git3-bird1
@ 2005-09-05 3:58 viro
2005-09-05 15:55 ` Alexey Dobriyan
0 siblings, 1 reply; 3+ messages in thread
From: viro @ 2005-09-05 3:58 UTC (permalink / raw)
To: linux-kernel
While waaaaay overdue, "fixes and sparse annotations" tree is finally
going public. This version is basically a starting point - there will be
much more stuff to merge.
Right now it builds with allmodconfig[1] on the following set:
alpha (UP and SMP), amd64 (UP and SMP), arm (RPC, versatile), i386, ia64,
m32r, m68k (sans sun3), ppc (6xx, 44x, chestnut), ppc64, sparc, sparc64,
s390 (31 and 64bit) and uml (i386 and amd64)[2].
Amount of sparse and gcc4 warnings is moderate on all of the
above - there's no "drowns everything in noise" stuff left. There _are_
nasty areas (drm, some of the sata, several mem* helpers with constant
arguments), but at least that's easy to isolate. Tracking build log
changes for regressions had been fairly easy so far; quite a few chunks
in there (as well as already merged stuff) had been found that way,
so for now I'd say that it's usable.
Current patchset is on ftp.linux.org.uk/pub/people/viro/ -
patch-2.6.13-git3-bird1.bz2 is combined patch, patchset/* is the splitup.
Long description of patches is in patchset/set*, short log is in the end of
this posting. Current build and sparse logs are in logs/*/{log17b,S-log17b}.
Eventually I'll probably have to use rcs for them - they are large and change
slowly...
Patchset will change pretty fast; for one thing, most of the stuff
in there is easily mergable, for another - sparse patches here are just
dealing with the most annoying noise sources. There will be more and folks
are more than welcome to send sane annotation patches for merge.
Have fun - it's just getting started...
[1] configs being tracked are of allmodconfig-with-fixed-subset variety; e.g.
alpha-UP is "set as much as possible to y or m, with CONFIG_SMP not set", etc.
See config/* for currently tracked ones.
[2] toolkit for cross-toolchains will be re-posted on anonftp pretty soon;
ditto for details on cross-build setups, etc.
Short log of the current patchset follows:
----------------------------------------------------------------------------
linus-delta Changes in Linus' tree since -git3
Infrastructure:
I0-kconfig Teaches allmodconfig to pin a set of options in given
state [NB: rz has another variant; this is just a temporary]
I1-CHECKFLAGS Allows to add stuff to CHECKFLAGS from command line
I2-disable-DI disables CONFIG_DEBUG_INFO for test builds
Kconfig fixes:
B2-rio rio is too broken to mess with; marked as such
B7-floppy sanitized and fixed floppy dependencies
B12-broken-on-big-endian new kconfig symbol: BROKEN_ON_BIG_ENDIAN.
B17-m32r-smc combination of M32R, SMC91X and ISA is broken
B22-mtd-xip MTD_XIP is there only for two subarchitectures of ARM - PXA
and SA1100 [not for merge; cleaner variant needed]
B23-8390 8390 fixes - part 1 (generic and arm/etherh)
B33-m68k-8390 8390 fixes - part 2 (m68k ones)
B41-s390-phy PHYLIB is broken on s390
B42-mga drm/mga is broken if AGP is not enabled
Pure compile fixes:
C0-envctrl envctrl fixes
C15-mv643xx_eth mv643xx_eth ifdefs [not for merge; dwmw2 has objections]
C32-segment missed gratitious includes of asm/segment.h
B40-mxser-sparc32 more sparc32 dependencies fallout
C33-mxser another missed asm/segment.h, real fix for problem B40 marks
C34-uli526x missing include in uli526x.c
C35-ipw2200 missing include (ipw2200)
C36-sunsu sunsu compile fixes
Misc bug fixes:
F6-zatm dereference of uninitialized pointer in zatm
Crap spotted by gcc and sparse:
O3-s2io-u64 s2io u64 use for uintptr_t
S0-chelsio chelsio sparse annotations
S1-e1000 iomem annotations (e1000)
S2-s2io-iomem iomem annotations (s2io)
S3-ipw2100 iomem annotations, NULL noise removal (ipw2100)
S4-scsi-ch __user annotations (drivers/scsi/ch.c)
S5-ahci iomem annotations (ahci)
S6-sata_nv iomem annotations (sata_nv)
S7-sata_sx4 iomem annotations (sata_sx4)
S8-sata_qstor enum safety (sata_qstor)
S9-aaci iomem annotations (aaci)
S10-ethtool __user annotations (ethtool)
S14-m32r-user basic __user annotations (m32r)
S15-armv-iomem basic iomem annotations (arm-versatile)
S16-m32r-iomem missing basic iomem annotations (m32r)
S17-ia64-user missing basic __user annotations (ia64)
S18-rpc-iomem saner casts in arm-rpc IOMEM()
S19-sparse-m32r pass definition of __BIG_ENDIAN__ to sparse (m32r)
m68k patches:
C16-dmasound-lvalues lvalues abuse in dmasound
C17-dmasound-extern compile fixes for dmsound (static vs. extern)
C18-sun3ints static vs. extern in sun3ints.h
C19-sun3_pgtable bogus function argument types (sun3_pgtable.h)
C20-amigaints static vs. extern in amigaints.h
C21-atyfb-typo dumb typo in atyfb
C22-mac8390 lvalues abuse in mac8390
C23-lance lvalues abuse in lance
C24-82596-apricot wrong ifdefs in 82596
C25-scc static vs. extern in scc
C26-m68k-reset memory input should be an lvalue (mac/misc.c)
C27-m68k-mul broken constraints on mulu.l
C28-isa_type isa_{type,sex} should be exported (m68k)
B34-oktagon oktagon makefile fix
B35-82596 Kconfig fix (82596)
B36-mac-fonts Kconfig fix (mac vs. FONTS)
T0-task_thread_info task_thread_info - part 1/5
T1-other-helpers task_thread_info - part 2/5
T2-includes task_thread_info - part 3/5
T3-m68k task_thread_info - part 4/5
T4-m68k-flags task_thread_info - part 5/5
m68k-adb.patch ADBREQ_RAW missing declaration (from m68k CVS)
S11-m68k-iomem basic iomem annotations (m68k)
S13-m68k-user basic __user annotations (m68k)
C37-amigahw gratitious namespace pollution in amigahw
UML patches:
jd1 -- jd9 Pending patches from jdike's 9-patch set
S12-uml-user basic __user annotations (uml)
UM1-stubs [UML] segv_stubs fixes
UM2-signal [UML] copy_sc_..._user_tt() fixes
UM4-uml-checker [UML] getting sparse to work for uml
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCHSET] 2.6.13-git3-bird1
2005-09-05 3:58 [PATCHSET] 2.6.13-git3-bird1 viro
@ 2005-09-05 15:55 ` Alexey Dobriyan
2005-09-05 16:03 ` viro
0 siblings, 1 reply; 3+ messages in thread
From: Alexey Dobriyan @ 2005-09-05 15:55 UTC (permalink / raw)
To: linux-kernel; +Cc: viro
On Mon, Sep 05, 2005 at 04:58:48AM +0100, viro@ZenIV.linux.org.uk wrote:
> While waaaaay overdue, "fixes and sparse annotations" tree is finally
> going public. This version is basically a starting point - there will be
> much more stuff to merge.
> Current patchset is on ftp.linux.org.uk/pub/people/viro/ -
> patch-2.6.13-git3-bird1.bz2 is combined patch, patchset/* is the splitup.
> Long description of patches is in patchset/set*, short log is in the end of
> this posting. Current build and sparse logs are in logs/*/{log17b,S-log17b}.
Those who want to help with endian annotations (sparse -Wbitwise) are
welcome at ftp://ftp.berlios.de/pub/linux-sparse/logs/
[allmodconfig + CONFIG_DEBUG_INFO=n] x [alpha, i386, parisc, ppc, ppc64,
s390, sh, sh64, sparc, sparc64, x86_64]
-git5 is compiling right now.
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCHSET] 2.6.13-git3-bird1
2005-09-05 15:55 ` Alexey Dobriyan
@ 2005-09-05 16:03 ` viro
2005-09-05 16:47 ` [PATCHSET] 2.6.13-git5-bird1 viro
0 siblings, 1 reply; 3+ messages in thread
From: viro @ 2005-09-05 16:03 UTC (permalink / raw)
To: Alexey Dobriyan; +Cc: linux-kernel
On Mon, Sep 05, 2005 at 07:55:22PM +0400, Alexey Dobriyan wrote:
> On Mon, Sep 05, 2005 at 04:58:48AM +0100, viro@ZenIV.linux.org.uk wrote:
> > While waaaaay overdue, "fixes and sparse annotations" tree is finally
> > going public. This version is basically a starting point - there will be
> > much more stuff to merge.
>
> > Current patchset is on ftp.linux.org.uk/pub/people/viro/ -
> > patch-2.6.13-git3-bird1.bz2 is combined patch, patchset/* is the splitup.
> > Long description of patches is in patchset/set*, short log is in the end of
> > this posting. Current build and sparse logs are in logs/*/{log17b,S-log17b}.
>
> Those who want to help with endian annotations (sparse -Wbitwise) are
> welcome at ftp://ftp.berlios.de/pub/linux-sparse/logs/
>
> [allmodconfig + CONFIG_DEBUG_INFO=n] x [alpha, i386, parisc, ppc, ppc64,
> s390, sh, sh64, sparc, sparc64, x86_64]
>
> -git5 is compiling right now.
-git5 has additional breakage:
* s390 crypto is b0rken; removal of workqueue that doesn't exist
* ppc44x missed s/u3/pm_message_t/
* sparc64 Kconfig changes need to be compensated for in drivers/char
Plus m68k and uml stuff need updates.
I'll post the updated patchset in a few and start clean rebuild; then the
logs will go.
^ permalink raw reply [flat|nested] 3+ messages in thread* [PATCHSET] 2.6.13-git5-bird1
2005-09-05 16:03 ` viro
@ 2005-09-05 16:47 ` viro
2005-09-05 21:20 ` [PATCHSET] 2.6.13-git5-bird2 viro
0 siblings, 1 reply; 3+ messages in thread
From: viro @ 2005-09-05 16:47 UTC (permalink / raw)
To: linux-kernel; +Cc: Alexey Dobriyan
> > [allmodconfig + CONFIG_DEBUG_INFO=n] x [alpha, i386, parisc, ppc, ppc64,
> > s390, sh, sh64, sparc, sparc64, x86_64]
> >
> > -git5 is compiling right now.
>
> -git5 has additional breakage:
> * s390 crypto is b0rken; removal of workqueue that doesn't exist
> * ppc44x missed s/u3/pm_message_t/
> * sparc64 Kconfig changes need to be compensated for in drivers/char
> Plus m68k and uml stuff need updates.
>
> I'll post the updated patchset in a few and start clean rebuild; then the
> logs will go.
OK, updated patchset in the same place:
ftp.linux.org.uk:/pub/people/viro/patchset/
ftp.linux.org.uk:/pub/people/viro/patch-2.6.13-git5-bird1.bz2
Old splitup had been moved to patchset-RC13-git3.
Changes:
* F6-zatm and B40-mxser-sparc32 merged upstream
* jd1--jd9 are partially merged, partially dropped - when Jeff posts
new set, it will get it.
* UM1-segv-stubs reduced to one chunk - that got missed in the
upstream merge
* UM2-signal merged upstream
* T4-m68k-flags updated due to m68k ptrace.c indent patch upstream.
Added:
* B43-serial gratitious includes of asm/serial.h in drivers/char
* B44-genrtc genrtc is not for sparc64
* C38-ppc44x-pm missed s/u32/pm_message_t/ in arch/ppc/syslib/ocp.c
* C39-s390 temporary fix for s390 mismerge
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCHSET] 2.6.13-git5-bird2
2005-09-05 16:47 ` [PATCHSET] 2.6.13-git5-bird1 viro
@ 2005-09-05 21:20 ` viro
2005-09-07 18:31 ` [PATCHSET] 2.6.13-git7-bird1 viro
0 siblings, 1 reply; 3+ messages in thread
From: viro @ 2005-09-05 21:20 UTC (permalink / raw)
To: linux-kernel
With several more patches (mostly - sparse regression fixing); same place,
ftp.linux.org.uk/pub/people/viro/{patch-2.6.13-git5-bird2.bz,patchset}
Added:
* O4-dm9000 missed s/u32/pm_message_t/ (dm9000)
* S20-wdt __user annotations (booke_wdt.c)
* S21-cx88 __user annotations (cx88-video.c)
* S22-ac3200 iomem annotations (ac3200.c)
* S23-forcedeth __user annotations (forcedeth.c)
* S24-proc NULL noise removal (proc/task_mmu.c)
* S25-page_alloc missing prototype (mm/page_alloc.c)
Logs are on ftp.linux.org.uk/pub/people/viro/logs/*log18a (gcc and sparse).
Looking some more into Alexey's sunrpc patch, have not merged yet...
^ permalink raw reply [flat|nested] 3+ messages in thread* [PATCHSET] 2.6.13-git7-bird1
2005-09-05 21:20 ` [PATCHSET] 2.6.13-git5-bird2 viro
@ 2005-09-07 18:31 ` viro
2005-09-12 19:17 ` [PATCHSET] 2.6.13-git12-bird1 Al Viro
0 siblings, 1 reply; 3+ messages in thread
From: viro @ 2005-09-07 18:31 UTC (permalink / raw)
To: linux-kernel
Patchset moved to -git7. News:
* sparse arguments fixed on ppc64 (dealt with regression)
* -Wundef gcc warnigns all dealt with on tracked targets
Note that sparse -Wundef is broken; logs this time are with sparse
wrapper that rips -Wundef from its arguments.
Patch is on ftp.linux.org.uk/pub/peole/viro/patch-2.6.13-git7-brid1.bz2,
its splitup is in usual place and logs are in logs/*/*log19.
Added:
S26-ppc64-sparse CHECKFLAGS on ppc64 got broken
C40-elf_class bogus symbol used in elf_aux.c
C41-xfs XFS __...._ENDIAN -Wundef warnings
O5-m68k-hardirq (m68k) hardirq checks were in wrong place
O6-simserial bogus #if (simserial)
O7-uml-mem bogus #if (arch/um/kernel/mem.c)
O8-hisax -Wundef fixes (hisax)
O9-smc-undef bogus #if (smc91x)
O10-ncr5380 -Wundef fixes (ncr5380)
O11-hamachi -Wundef fixes (hamachi)
O12-ncr53c406 bogus #if (ncr53c406)
Merged upstream:
B35-82596
B41-s390-phy
B44-genrtc
C33-mxser
C34-uli526x
C36-sunsu
S0-chelsio
S1-e1000
S2-s2io-iomem
S3-ipw2100
S10-ethtool
Updated:
S5-ahci
S7-sata_sx4
C39-s390
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCHSET] 2.6.13-git12-bird1
2005-09-07 18:31 ` [PATCHSET] 2.6.13-git7-bird1 viro
@ 2005-09-12 19:17 ` Al Viro
2005-09-12 20:42 ` [PATCH] n_r3964: drop bogus fmt casts Alexey Dobriyan
0 siblings, 1 reply; 3+ messages in thread
From: Al Viro @ 2005-09-12 19:17 UTC (permalink / raw)
To: linux-kernel
Patchset moved to -git12. News:
* playing catch-up with spinlock changes (m68k build got broken)
* playing catch-up with kbuild changes (arm, uml)
* usual assorted build fixes
* assorted sparse annotations
* beginning of endianness annotations merge: RPC patches from Alexey
* beginning of linux/irq.h work
Patch is in usual place. Patch itself is patch-2.6.13-git12-bird1.bz2,
splitup is in patchset/, logs in logs/*/*log21c.
Shortlog follows.
Alexey Dobriyan:
* sunrpc endianness annotations
* lockd endianness annotations
* nfs endianness annotations
Russell King:
* assorted arm annotations
Al Viro:
* C99 initializers (ray_cs)
* OUTPUT_ARCH() on ppc should be powerpc:common
* UML early build sanitized
* __iomem annotations (epca)
* __iomem annotations (i810-i2c)
* __iomem annotations (sata_promise)
* __iomem annotations (sata_sil)
* __iomem annotations (sata_vsc)
* __user annotations (saa6588)
* beginning of linux/irq.h cleanup - amd64
* bogus casts in lne390
* cyblafb: portability fixes, sanitized work with pointers
* fixed dependency in early arm build
* ibm_emac annotations
* missing include (cs89x0)
* s2io: use %p, damnit...
* sparc exports: no more wanking with weak aliases for .div et.al.
* trivial sparse warnings in net/*
* uml kconfig sanitized around drivers/net
* updated m68k vmlinux.lds to include LOCK_TEXT
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH] n_r3964: drop bogus fmt casts
2005-09-12 19:17 ` [PATCHSET] 2.6.13-git12-bird1 Al Viro
@ 2005-09-12 20:42 ` Alexey Dobriyan
2005-09-12 20:39 ` Al Viro
0 siblings, 1 reply; 3+ messages in thread
From: Alexey Dobriyan @ 2005-09-12 20:42 UTC (permalink / raw)
To: Al Viro; +Cc: linux-kernel
* print pointers with %p
* casting unsigned int structure field to int and printing it with %d...
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
---
drivers/char/n_r3964.c | 84 ++++++++++++++++++++++++-------------------------
1 files changed, 42 insertions(+), 42 deletions(-)
--- linux-vanilla/drivers/char/n_r3964.c
+++ linux-r3964/drivers/char/n_r3964.c
@@ -229,8 +229,8 @@ static int __init r3964_init(void)
TRACE_L("line discipline %d registered", N_R3964);
TRACE_L("flags=%x num=%x", tty_ldisc_N_R3964.flags,
tty_ldisc_N_R3964.num);
- TRACE_L("open=%x", (int)tty_ldisc_N_R3964.open);
- TRACE_L("tty_ldisc_N_R3964 = %x", (int)&tty_ldisc_N_R3964);
+ TRACE_L("open=%p", tty_ldisc_N_R3964.open);
+ TRACE_L("tty_ldisc_N_R3964 = %p", &tty_ldisc_N_R3964);
}
else
{
@@ -267,8 +267,8 @@ static void add_tx_queue(struct r3964_in
spin_unlock_irqrestore(&pInfo->lock, flags);
- TRACE_Q("add_tx_queue %x, length %d, tx_first = %x",
- (int)pHeader, pHeader->length, (int)pInfo->tx_first );
+ TRACE_Q("add_tx_queue %p, length %d, tx_first = %p",
+ pHeader, pHeader->length, pInfo->tx_first );
}
static void remove_from_tx_queue(struct r3964_info *pInfo, int error_code)
@@ -285,10 +285,10 @@ static void remove_from_tx_queue(struct
return;
#ifdef DEBUG_QUEUE
- printk("r3964: remove_from_tx_queue: %x, length %d - ",
- (int)pHeader, (int)pHeader->length );
+ printk("r3964: remove_from_tx_queue: %p, length %u - ",
+ pHeader, pHeader->length );
for(pDump=pHeader;pDump;pDump=pDump->next)
- printk("%x ", (int)pDump);
+ printk("%p ", pDump);
printk("\n");
#endif
@@ -319,10 +319,10 @@ static void remove_from_tx_queue(struct
spin_unlock_irqrestore(&pInfo->lock, flags);
kfree(pHeader);
- TRACE_M("remove_from_tx_queue - kfree %x",(int)pHeader);
+ TRACE_M("remove_from_tx_queue - kfree %p",pHeader);
- TRACE_Q("remove_from_tx_queue: tx_first = %x, tx_last = %x",
- (int)pInfo->tx_first, (int)pInfo->tx_last );
+ TRACE_Q("remove_from_tx_queue: tx_first = %p, tx_last = %p",
+ pInfo->tx_first, pInfo->tx_last );
}
static void add_rx_queue(struct r3964_info *pInfo, struct r3964_block_header *pHeader)
@@ -346,9 +346,9 @@ static void add_rx_queue(struct r3964_in
spin_unlock_irqrestore(&pInfo->lock, flags);
- TRACE_Q("add_rx_queue: %x, length = %d, rx_first = %x, count = %d",
- (int)pHeader, pHeader->length,
- (int)pInfo->rx_first, pInfo->blocks_in_rx_queue);
+ TRACE_Q("add_rx_queue: %p, length = %d, rx_first = %p, count = %d",
+ pHeader, pHeader->length,
+ pInfo->rx_first, pInfo->blocks_in_rx_queue);
}
static void remove_from_rx_queue(struct r3964_info *pInfo,
@@ -360,10 +360,10 @@ static void remove_from_rx_queue(struct
if(pHeader==NULL)
return;
- TRACE_Q("remove_from_rx_queue: rx_first = %x, rx_last = %x, count = %d",
- (int)pInfo->rx_first, (int)pInfo->rx_last, pInfo->blocks_in_rx_queue );
- TRACE_Q("remove_from_rx_queue: %x, length %d",
- (int)pHeader, (int)pHeader->length );
+ TRACE_Q("remove_from_rx_queue: rx_first = %p, rx_last = %p, count = %d",
+ pInfo->rx_first, pInfo->rx_last, pInfo->blocks_in_rx_queue );
+ TRACE_Q("remove_from_rx_queue: %p, length %u",
+ pHeader, pHeader->length );
spin_lock_irqsave(&pInfo->lock, flags);
@@ -401,10 +401,10 @@ static void remove_from_rx_queue(struct
spin_unlock_irqrestore(&pInfo->lock, flags);
kfree(pHeader);
- TRACE_M("remove_from_rx_queue - kfree %x",(int)pHeader);
+ TRACE_M("remove_from_rx_queue - kfree %p",pHeader);
- TRACE_Q("remove_from_rx_queue: rx_first = %x, rx_last = %x, count = %d",
- (int)pInfo->rx_first, (int)pInfo->rx_last, pInfo->blocks_in_rx_queue );
+ TRACE_Q("remove_from_rx_queue: rx_first = %p, rx_last = %p, count = %d",
+ pInfo->rx_first, pInfo->rx_last, pInfo->blocks_in_rx_queue );
}
static void put_char(struct r3964_info *pInfo, unsigned char ch)
@@ -506,8 +506,8 @@ static void transmit_block(struct r3964_
if(tty->driver->write_room)
room=tty->driver->write_room(tty);
- TRACE_PS("transmit_block %x, room %d, length %d",
- (int)pBlock, room, pBlock->length);
+ TRACE_PS("transmit_block %p, room %d, length %d",
+ pBlock, room, pBlock->length);
while(pInfo->tx_position < pBlock->length)
{
@@ -588,7 +588,7 @@ static void on_receive_block(struct r396
/* prepare struct r3964_block_header: */
pBlock = kmalloc(length+sizeof(struct r3964_block_header), GFP_KERNEL);
- TRACE_M("on_receive_block - kmalloc %x",(int)pBlock);
+ TRACE_M("on_receive_block - kmalloc %p",pBlock);
if(pBlock==NULL)
return;
@@ -868,11 +868,11 @@ static int enable_signals(struct r3964_i
if(pMsg)
{
kfree(pMsg);
- TRACE_M("enable_signals - msg kfree %x",(int)pMsg);
+ TRACE_M("enable_signals - msg kfree %p",pMsg);
}
}
kfree(pClient);
- TRACE_M("enable_signals - kfree %x",(int)pClient);
+ TRACE_M("enable_signals - kfree %p",pClient);
return 0;
}
}
@@ -890,7 +890,7 @@ static int enable_signals(struct r3964_i
{
/* add client to client list */
pClient=kmalloc(sizeof(struct r3964_client_info), GFP_KERNEL);
- TRACE_M("enable_signals - kmalloc %x",(int)pClient);
+ TRACE_M("enable_signals - kmalloc %p",pClient);
if(pClient==NULL)
return -ENOMEM;
@@ -954,7 +954,7 @@ static void add_msg(struct r3964_client_
queue_the_message:
pMsg = kmalloc(sizeof(struct r3964_message), GFP_KERNEL);
- TRACE_M("add_msg - kmalloc %x",(int)pMsg);
+ TRACE_M("add_msg - kmalloc %p",pMsg);
if(pMsg==NULL) {
return;
}
@@ -1067,11 +1067,11 @@ static int r3964_open(struct tty_struct
struct r3964_info *pInfo;
TRACE_L("open");
- TRACE_L("tty=%x, PID=%d, disc_data=%x",
- (int)tty, current->pid, (int)tty->disc_data);
+ TRACE_L("tty=%p, PID=%d, disc_data=%p",
+ tty, current->pid, tty->disc_data);
pInfo=kmalloc(sizeof(struct r3964_info), GFP_KERNEL);
- TRACE_M("r3964_open - info kmalloc %x",(int)pInfo);
+ TRACE_M("r3964_open - info kmalloc %p",pInfo);
if(!pInfo)
{
@@ -1080,26 +1080,26 @@ static int r3964_open(struct tty_struct
}
pInfo->rx_buf = kmalloc(RX_BUF_SIZE, GFP_KERNEL);
- TRACE_M("r3964_open - rx_buf kmalloc %x",(int)pInfo->rx_buf);
+ TRACE_M("r3964_open - rx_buf kmalloc %p",pInfo->rx_buf);
if(!pInfo->rx_buf)
{
printk(KERN_ERR "r3964: failed to alloc receive buffer\n");
kfree(pInfo);
- TRACE_M("r3964_open - info kfree %x",(int)pInfo);
+ TRACE_M("r3964_open - info kfree %p",pInfo);
return -ENOMEM;
}
pInfo->tx_buf = kmalloc(TX_BUF_SIZE, GFP_KERNEL);
- TRACE_M("r3964_open - tx_buf kmalloc %x",(int)pInfo->tx_buf);
+ TRACE_M("r3964_open - tx_buf kmalloc %p",pInfo->tx_buf);
if(!pInfo->tx_buf)
{
printk(KERN_ERR "r3964: failed to alloc transmit buffer\n");
kfree(pInfo->rx_buf);
- TRACE_M("r3964_open - rx_buf kfree %x",(int)pInfo->rx_buf);
+ TRACE_M("r3964_open - rx_buf kfree %p",pInfo->rx_buf);
kfree(pInfo);
- TRACE_M("r3964_open - info kfree %x",(int)pInfo);
+ TRACE_M("r3964_open - info kfree %p",pInfo);
return -ENOMEM;
}
@@ -1154,11 +1154,11 @@ static void r3964_close(struct tty_struc
if(pMsg)
{
kfree(pMsg);
- TRACE_M("r3964_close - msg kfree %x",(int)pMsg);
+ TRACE_M("r3964_close - msg kfree %p",pMsg);
}
}
kfree(pClient);
- TRACE_M("r3964_close - client kfree %x",(int)pClient);
+ TRACE_M("r3964_close - client kfree %p",pClient);
pClient=pNext;
}
/* Remove jobs from tx_queue: */
@@ -1177,11 +1177,11 @@ static void r3964_close(struct tty_struc
/* Free buffers: */
wake_up_interruptible(&pInfo->read_wait);
kfree(pInfo->rx_buf);
- TRACE_M("r3964_close - rx_buf kfree %x",(int)pInfo->rx_buf);
+ TRACE_M("r3964_close - rx_buf kfree %p",pInfo->rx_buf);
kfree(pInfo->tx_buf);
- TRACE_M("r3964_close - tx_buf kfree %x",(int)pInfo->tx_buf);
+ TRACE_M("r3964_close - tx_buf kfree %p",pInfo->tx_buf);
kfree(pInfo);
- TRACE_M("r3964_close - info kfree %x",(int)pInfo);
+ TRACE_M("r3964_close - info kfree %p",pInfo);
}
static ssize_t r3964_read(struct tty_struct *tty, struct file *file,
@@ -1234,7 +1234,7 @@ repeat:
count = sizeof(struct r3964_client_message);
kfree(pMsg);
- TRACE_M("r3964_read - msg kfree %x",(int)pMsg);
+ TRACE_M("r3964_read - msg kfree %p",pMsg);
if (copy_to_user(buf,&theMsg, count))
return -EFAULT;
@@ -1279,7 +1279,7 @@ static ssize_t r3964_write(struct tty_st
* Allocate a buffer for the data and copy it from the buffer with header prepended
*/
new_data = kmalloc (count+sizeof(struct r3964_block_header), GFP_KERNEL);
- TRACE_M("r3964_write - kmalloc %x",(int)new_data);
+ TRACE_M("r3964_write - kmalloc %p",new_data);
if (new_data == NULL) {
if (pInfo->flags & R3964_DEBUG)
{
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2005-09-28 23:06 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-09-28 23:05 [PATCH] n_r3964: drop bogus fmt casts Al Viro
-- strict thread matches above, loose matches on Subject: below --
2005-09-05 3:58 [PATCHSET] 2.6.13-git3-bird1 viro
2005-09-05 15:55 ` Alexey Dobriyan
2005-09-05 16:03 ` viro
2005-09-05 16:47 ` [PATCHSET] 2.6.13-git5-bird1 viro
2005-09-05 21:20 ` [PATCHSET] 2.6.13-git5-bird2 viro
2005-09-07 18:31 ` [PATCHSET] 2.6.13-git7-bird1 viro
2005-09-12 19:17 ` [PATCHSET] 2.6.13-git12-bird1 Al Viro
2005-09-12 20:42 ` [PATCH] n_r3964: drop bogus fmt casts Alexey Dobriyan
2005-09-12 20:39 ` Al Viro
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox