linux-next: Tree for May 3
Subsystems (6)
Hi all,
Changes since 20100430:
Dropped trees: tmio-mmc (long unresolved conflicts and unable to fetch)
hwlat (at the maintainer's request)
My fixes tree is empty.
The usb.current tree lost its conflict.
The v4l-dvb tree still has its build failure, so I used the version from next-20100409.
The net tree gained a build failure so I used the version from next-20100430.
The bk-ioctl tree lost its build failure and 2 conflicts.
The driver-core tree gained a build failure for which I applied a patch.
The usb tree lost two of its build failures bit still has one more for which I have reverted a commit.
----------------------------------------------------------------------------
I have created today's linux-next tree atgit://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
(patches at http://www.kernel.org/pub/linux/kernel/v2.6/next/ ). If you are tracking the linux-next tree using git, you should not use "git pull" to do so as that will try to merge the new linux-next release with the old one. You should use "git fetch" as mentioned in the FAQ on the wiki (see below).
You can see which trees have been included by looking in the Next/Trees file in the source. There are also quilt-import.log and merge.log files in the Next directory. Between each merge, the tree was built with a ppc64_defconfig for powerpc and an allmodconfig for x86_64. After the final fixups (if any), it is also built with powerpc allnoconfig (32 and 64 bit), ppc44x_defconfig and allyesconfig (minus CONFIG_PROFILE_ALL_BRANCHES - this fails its final link) and i386, sparc and sparc64 defconfig. These builds also have CONFIG_ENABLE_WARN_DEPRECATED, CONFIG_ENABLE_MUST_CHECK and CONFIG_DEBUG_INFO disabled when necessary.
Below is a summary of the state of the merge.
We are up to 162 trees (counting Linus' and 22 trees of patches pending for Linus' tree), more are welcome (even if they are currently empty). Thanks to those who have contributed, and to those who haven't, please do.
Status of my local build tests will be at
http://kisskb.ellerman.id.au/linux-next . If maintainers want to give advice about cross compilers/configs that work, we are always open to add more builds.
Thanks to Jan Dittmer for adding the linux-next tree to his build tests at http://l4x.org/k/ , the guys at http://test.kernel.org/ and Randy Dunlap for doing many randconfig builds.
There is a wiki covering stuff to do with linux-next at
http://linux.f-seidel.de/linux-next/pmwiki/ . Thanks to Frank Seidel.
Signature · 239 lines
Cheers, Stephen Rothwell [email protected] $ git checkout master $ git reset --hard stable Merging origin/master Merging fixes/fixes Merging arm-current/master Merging m68k-current/for-linus Merging powerpc-merge/merge Merging sparc-current/master Merging scsi-rc-fixes/master Merging net-current/master Applying: ar9170: fix for driver-core ABI change Merging sound-current/for-linus Merging pci-current/for-linus Merging wireless-current/master Merging kbuild-current/for-linus Merging quilt/driver-core.current Merging quilt/tty.current Merging quilt/usb.current Merging quilt/staging.current Applying: staging: update gfp/slab.h includes Merging cpufreq-current/fixes Merging input-current/for-linus Merging md-current/for-linus Merging audit-current/for-linus Merging crypto-current/master Merging ide-curent/master Merging dwmw2/master Merging gcl-current/merge Merging arm/devel CONFLICT (content): Merge conflict in arch/arm/Kconfig Applying: arm: update gfp/slab.h includes Merging davinci/davinci-next Applying: davinci: update gfp/slab.h includes Merging i.MX/for-next Merging msm/for-next Merging omap/for-next Merging pxa/for-next Merging samsung/next-samsung Merging avr32/avr32-arch Merging blackfin/for-linus Merging cris/for-next Merging ia64/test Merging m68k/for-next Merging m68knommu/for-next Merging microblaze/next Merging mips/mips-for-linux-next Merging parisc/next Merging powerpc/next Merging 4xx/next Merging 52xx-and-virtex/next Merging galak/next Merging s390/features Merging sh/master Merging genesis/master Merging sparc/master Merging xtensa/master Merging ceph/for-next Merging cifs/master Merging configfs/linux-next Merging ecryptfs/next Merging ext3/for_next Merging ext4/next Merging fatfs/master Merging fuse/for-next Merging gfs2/master Merging jfs/next Merging logfs/master Merging nfs/linux-next Merging nfsd/nfsd-next Merging nilfs2/for-next Merging ocfs2/linux-next Applying: ocfs2: update gfp/slab.h includes Merging squashfs/master Merging udf/for_next Merging v9fs/for-next CONFLICT (content): Merge conflict in fs/9p/vfs_super.c Merging ubifs/linux-next Merging xfs/master Merging vfs/for-next CONFLICT (content): Merge conflict in fs/cifs/file.c CONFLICT (content): Merge conflict in fs/namei.c CONFLICT (content): Merge conflict in fs/nfs/inode.c CONFLICT (content): Merge conflict in fs/nfsd/nfs4xdr.c CONFLICT (content): Merge conflict in fs/nfsd/vfs.c CONFLICT (content): Merge conflict in fs/ufs/inode.c CONFLICT (content): Merge conflict in fs/xfs/linux-2.6/xfs_super.c CONFLICT (content): Merge conflict in security/tomoyo/realpath.c Merging pci/linux-next Merging hid/for-next Merging quilt/i2c Merging bjdooks-i2c/next-i2c Merging quilt/jdelvare-hwmon Merging quilt/kernel-doc Merging v4l-dvb/master CONFLICT (content): Merge conflict in drivers/input/input.c Applying: v4l-dvb: update gfp/slab.h includes $ git reset --hard HEAD^ Merging refs/next/20100409/v4l-dvb CONFLICT (content): Merge conflict in drivers/media/video/meye.c CONFLICT (content): Merge conflict in drivers/media/video/soc_camera.c CONFLICT (content): Merge conflict in drivers/staging/cx25821/cx25821-audio-upstream.c Applying: v4l-dvb: update gfp/slab.h includes Merging kbuild/for-next Merging kconfig/for-next Merging ide/master Merging libata/NEXT Merging infiniband/for-next Merging acpi/test Applying: acpi: update gfp/slab.h includes Merging ieee1394/for-next Merging ubi/linux-next Merging kvm/linux-next Applying: kvm: powerpc: use of kzalloc/kfree requires including slab.h Merging dlm/next Merging ibft/master Merging scsi/master Merging async_tx/next Merging net/master CONFLICT (content): Merge conflict in drivers/scsi/iscsi_tcp.c $ git reset --hard HEAD^ Merging refs/next/20100430/net CONFLICT (content): Merge conflict in drivers/scsi/iscsi_tcp.c Merging wireless/master CONFLICT (content): Merge conflict in drivers/net/wireless/libertas_tf/cmd.c CONFLICT (content): Merge conflict in drivers/net/wireless/libertas_tf/main.c Applying: wireless: update gfp/slab.h includes Merging mtd/master CONFLICT (content): Merge conflict in drivers/mtd/mtdcore.c Applying: mtd: update gfp/slab.h includes Merging crypto/master CONFLICT (content): Merge conflict in drivers/crypto/mv_cesa.c Merging sound/for-next Merging cpufreq/next Merging quilt/rr CONFLICT (content): Merge conflict in drivers/net/virtio_net.c CONFLICT (content): Merge conflict in include/linux/mod_devicetable.h CONFLICT (content): Merge conflict in scripts/mod/file2alias.c Merging mmc/next Merging input/next Merging lsm/for-next Merging block/for-next CONFLICT (content): Merge conflict in fs/ext3/fsync.c CONFLICT (content): Merge conflict in fs/ext4/fsync.c Merging quilt/device-mapper Merging embedded/master Merging firmware/master Merging pcmcia/master CONFLICT (content): Merge conflict in drivers/net/pcmcia/3c589_cs.c Merging battery/master Merging leds/for-mm Merging backlight/for-mm Merging kgdb/kgdb-next Applying: kgdb: update for sysrq handling change Applying: kdb: update gfp/slab.h includes Merging slab/for-next Merging uclinux/for-next Merging md/for-next Merging mfd/for-next CONFLICT (content): Merge conflict in drivers/dma/Makefile CONFLICT (add/add): Merge conflict in drivers/dma/timb_dma.c Merging hdlc/hdlc-next Merging drm/drm-next CONFLICT (content): Merge conflict in drivers/gpu/drm/i915/i915_drv.h CONFLICT (content): Merge conflict in drivers/gpu/drm/radeon/r300.c Merging viafb/viafb-next Merging voltage/for-next Merging security-testing/next Merging lblnet/master Merging agp/agp-next Merging uwb/for-upstream Merging watchdog/master Merging bdev/master Merging dwmw2-iommu/master Merging cputime/cputime Merging osd/linux-next Merging jc_docs/docs-next Merging nommu/master Merging trivial/for-next Merging audit/for-next Merging quilt/aoe Merging suspend/linux-next Merging bluetooth/master Merging fsnotify/for-next Applying: fsnotify: update gfp/slab.h includes Merging irda/for-next CONFLICT (content): Merge conflict in drivers/net/irda/irda-usb.c Merging drbd/for-jens Merging catalin/for-next Merging alacrity/linux-next CONFLICT (content): Merge conflict in include/linux/Kbuild CONFLICT (content): Merge conflict in lib/Kconfig Applying: vbus: use of kzalloc/kfree requires the include of slab.h Applying: vbus: update gfp/slab.h includes Merging i7core_edac/linux_next Merging devicetree/next-devicetree Merging spi/next-spi Merging omap_dss2/for-next Merging tip/auto-latest CONFLICT (content): Merge conflict in Documentation/feature-removal-schedule.txt Applying: lockdep: Fix redundant_hardirqs_on incremented with irqs enabled Merging edac-amd/for-next Merging oprofile/for-next Merging percpu/for-next Merging workqueues/for-next Merging sfi/sfi-test Merging asm-generic/next Merging hwpoison/hwpoison Merging sysctl/master Merging bkl-core/bkl/core Merging bkl-procfs/bkl/procfs Merging bkl-ioctl/bkl/ioctl CONFLICT (content): Merge conflict in arch/cris/arch-v10/drivers/ds1302.c CONFLICT (content): Merge conflict in drivers/block/pktcdvd.c Merging quilt/driver-core CONFLICT (content): Merge conflict in drivers/base/platform.c CONFLICT (content): Merge conflict in drivers/staging/comedi/drivers/quatech_daqp_cs.c Applying: md: fixup for sysfs_get_dirent API change Merging quilt/tty CONFLICT (content): Merge conflict in include/linux/tty.h Merging quilt/usb CONFLICT (content): Merge conflict in drivers/input/tablet/acecad.c CONFLICT (content): Merge conflict in drivers/input/tablet/kbtab.c CONFLICT (content): Merge conflict in drivers/input/tablet/wacom_sys.c CONFLICT (delete/modify): sound/usb/usbaudio.c deleted in HEAD and modified in quilt/usb. Version quilt/usb of sound/usb/usbaudio.c left in tree. $ git rm -f sound/usb/usbaudio.c Applying: usb: update gfp/slab.h includes Applying: sound: fixup for usb_buffer_alloc/free rename Merging staging-next/staging-next CONFLICT (content): Merge conflict in drivers/staging/arlan/arlan-main.c CONFLICT (content): Merge conflict in drivers/staging/comedi/drivers/cb_das16_cs.c CONFLICT (content): Merge conflict in drivers/staging/cx25821/cx25821-alsa.c CONFLICT (content): Merge conflict in drivers/staging/dt3155/dt3155_drv.c CONFLICT (content): Merge conflict in drivers/staging/netwave/netwave_cs.c Merging slabh/slabh Merging scsi-post-merge/master [master 528af62] Revert "usb: otg: twl4030: use the global ULPI register definitions"
PATCH 1/1 power: fix block_io.c printk warning
From: Randy Dunlap <[email protected]>
Fix printk format warning in block_io.c:
kernel/power/block_io.c:41: warning: format '%ld' expects type 'long int', but argument 2 has type 'sector_t'
--- kernel/power/block_io.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
kernel/power/block_io.c +2 -2
@@ -37,8 +37,8 @@ static int submit(int rw, struct block_d bio->bi_end_io = end_swap_bio_read;if (bio_add_page (bio, page,PAGE_SIZE ,0 ) <PAGE_SIZE ) { -printk (KERN_ERR "PM: Adding page to bio failed at %ld\n" , - sector); +printk (KERN_ERR "PM: Adding page to bio failed at %llu\n" , + (unsigned long long )sector);bio_put (bio);return -EFAULT ; }
PATCH 1/1 usbserial: fix mos7720 dependencies
In reply to Stephen RothwellFrom: Randy Dunlap <[email protected]>
Fix mos7720 Kconfig dependencies.
When an enabled bool selects a tristate, the tristate becomes =y, even if it should be limited to modular, so limit the bool kconfig option to configs that will build cleanly.
Also change the if-block to a simple depends on.
drivers/built-in.o: In function `mos7720_release':
mos7720.c:(.text+0xad432): undefined reference to parport_remove_port' drivers/built-in.o: In function mos7715_parport_init':
mos7720.c:(.text+0xae197): undefined reference to parport_register_port' mos7720.c:(.text+0xae210): undefined reference to parport_announce_port' drivers/built-in.o:(.data+0x201c8): undefined reference to parport_ieee1284_read_nibble' drivers/built-in.o:(.data+0x201d0): undefined reference to parport_ieee1284_read_byte'
--- drivers/usb/serial/Kconfig | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
drivers/usb/serial/Kconfig +2 -3
@@ -425,16 +425,15 @@ config USB_SERIAL_MOS7720 To compile this driver as a module, choose M here: the module will be called mos7720. -if USB_SERIAL_MOS7720 config USB_SERIAL_MOS7715_PARPORT bool "Support for parallel port on the Moschip 7715" + depends on USB_SERIAL_MOS7720 + depends on PARPORT=y || PARPORT=USB_SERIAL_MOS7720 select PARPORT_NOT_PC - depends on PARPORT ---help--- Say Y if you have a Moschip 7715 device and would like to use the parallel port it provides. The port will register with the parport subsystem as a low-level driver. -endif config USB_SERIAL_MOS7840 tristate "USB Moschip 7840/7820 USB Serial Driver"
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
PATCH 1/1 power: fix block_io.c printk warning
In reply to Stephen RothwellFrom: Randy Dunlap <[email protected]>
Fix printk format warning in block_io.c:
kernel/power/block_io.c:41: warning: format '%ld' expects type 'long int', but argument 2 has type 'sector_t'
--- kernel/power/block_io.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
kernel/power/block_io.c +2 -2
@@ -37,8 +37,8 @@ static int submit(int rw, struct block_d bio->bi_end_io = end_swap_bio_read;if (bio_add_page (bio, page,PAGE_SIZE ,0 ) <PAGE_SIZE ) { -printk (KERN_ERR "PM: Adding page to bio failed at %ld\n" , - sector); +printk (KERN_ERR "PM: Adding page to bio failed at %llu\n" , + (unsigned long long )sector);bio_put (bio);return -EFAULT ; }
Rafael J. Wysocki
AppliedRe: [PATCH -next] power: fix block_io.c printk warning
Quoted 8 lines · Randy Dunlap
From: Randy Dunlap <[email protected]>
Fix printk format warning in
block_io.c:
kernel/power/block_io.c:41: warning: format '%ld' expects type 'long int', but argument 2 has type 'sector_t'Signed-off-by Randy Dunlap <[email protected]>Cc "Rafael J. Wysocki" <[email protected]>
Applied to suspend-2.6/linux-next.
Thanks,
Rafael
Quoted 19 lines
--- kernel/power/block_io.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)kernel/power/block_io.c +2
-2@@ -37,8 +37,8 @@ static int submit(int rw, struct block_d bio->bi_end_io = end_swap_bio_read;if (bio_add_page (bio, page,PAGE_SIZE ,0 ) <PAGE_SIZE ) { -printk (KERN_ERR "PM: Adding page to bio failed at %ld\n" , - sector); +printk (KERN_ERR "PM: Adding page to bio failed at %llu\n" , + (unsigned long long )sector);bio_put (bio);return -EFAULT ; }
Rafael J. Wysocki
AppliedRe: [PATCH -next] power: fix block_io.c printk warning
In reply to Randy DunlapQuoted 8 lines · Randy Dunlap
From: Randy Dunlap <[email protected]>
Fix printk format warning in
block_io.c:
kernel/power/block_io.c:41: warning: format '%ld' expects type 'long int', but argument 2 has type 'sector_t'Signed-off-by Randy Dunlap <[email protected]>Cc "Rafael J. Wysocki" <[email protected]>
Applied to suspend-2.6/linux-next.
Thanks,
Rafael
Quoted 19 lines
--- kernel/power/block_io.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)kernel/power/block_io.c +2
-2@@ -37,8 +37,8 @@ static int submit(int rw, struct block_d bio->bi_end_io = end_swap_bio_read;if (bio_add_page (bio, page,PAGE_SIZE ,0 ) <PAGE_SIZE ) { -printk (KERN_ERR "PM: Adding page to bio failed at %ld\n" , - sector); +printk (KERN_ERR "PM: Adding page to bio failed at %llu\n" , + (unsigned long long )sector);bio_put (bio);return -EFAULT ; }
PATCH 1/1 staging: fix cxt1e1 module names
In reply to Stephen RothwellFrom: Randy Dunlap <[email protected]>
Lots of cxt1e1 source code uses THIS_MODULE->name, which won't build when CONFIG_MODULES is not enabled, so use KBUILD_MODNAME instead.
--- drivers/staging/cxt1e1/hwprobe.c | 9 +++++---- drivers/staging/cxt1e1/linux.c | 16 ++++++++-------- drivers/staging/cxt1e1/musycc.c | 4 ++-- drivers/staging/cxt1e1/pmcc4_drv.c | 13 ++++++++----- drivers/staging/cxt1e1/sbeproc.c | 4 ++-- 5 files changed, 25 insertions(+), 21 deletions(-)
drivers/staging/cxt1e1/musycc.c +2 -2
@@ -960,13 +960,13 @@ musycc_init (ci_t * ci)if (max_mru >0xffe ) {printk (KERN_WARNING "%s: Maximum allowed MRU exceeded, resetting %d to %d.\n" , -THIS_MODULE ->name, max_mru,0xffe ); +KBUILD_MODNAME , max_mru,0xffe ); max_mru =0xffe ; }if (max_mtu >0xffe ) {printk (KERN_WARNING "%s: Maximum allowed MTU exceeded, resetting %d to %d.\n" , -THIS_MODULE ->name, max_mtu,0xffe ); +KBUILD_MODNAME , max_mtu,0xffe ); max_mtu =0xffe ; }#ifdef SBE_WAN256T3_ENABLE
drivers/staging/cxt1e1/pmcc4_drv.c +8 -5
@@ -171,10 +171,11 @@ sbecom_set_loglevel (int d) {if (log_level != d) { -printk ("%s: log level changed from %d to %d\n" ,THIS_MODULE ->name, log_level, d); +printk ("%s: log level changed from %d to %d\n" , +KBUILD_MODNAME , log_level, d); log_level = d;/* set new */ }else -printk ("%s: log level is %d\n" ,THIS_MODULE ->name, log_level); +printk ("%s: log level is %d\n" ,KBUILD_MODNAME , log_level); } }
@@ -221,7 +222,7 @@ c4_new (void *hi) ci->brdno = ci->next ? ci->next->brdno +1 :0 ; }else printk (KERN_WARNING "%s: failed CI malloc, size %u.\n" , -THIS_MODULE ->name, (unsigned int )sizeof (ci_t)); +KBUILD_MODNAME , (unsigned int )sizeof (ci_t));if (CI ==0 )CI = ci;/* DEBUG, only board 0 usage */
@@ -545,7 +546,8 @@ c4_watchdog (ci_t * ci)if (drvr_state !=SBE_DRVR_AVAILABLE ) {if (log_level >=LOG_MONITOR ) -printk ("%s: drvr not available (%x)\n" ,THIS_MODULE ->name, drvr_state); +printk ("%s: drvr not available (%x)\n" , +KBUILD_MODNAME , drvr_state);return ; }#if 0
@@ -848,7 +850,8 @@ c4_init (ci_t * ci, u_char *func0, u_cha }else {printk (KERN_WARNING "%s: failed mch_t malloc, port %d channel %d size %u.\n" , -THIS_MODULE ->name, portnum, j, (unsigned int )sizeof (mch_t)); +KBUILD_MODNAME , portnum, j, + (unsigned int )sizeof (mch_t));break ; } }
drivers/staging/cxt1e1/linux.c +8 -8
@@ -338,7 +338,7 @@ chan_open (struct net_device * ndev)if ((ret =hdlc_open (ndev))) { -printk ("%s: hdlc_open failure, err %d.\n" ,THIS_MODULE ->name, ret); +printk ("%s: hdlc_open failure, err %d.\n" ,KBUILD_MODNAME , ret);return ret; }if ((ret =c4_chan_up (priv->ci, priv->channum)))
@@ -1263,33 +1263,33 @@ c4_mod_init (void) {int rtn; -printk (KERN_WARNING "%s: %s\n" ,THIS_MODULE ->name, pmcc4_OSSI_release); +printk (KERN_WARNING "%s: %s\n" ,KBUILD_MODNAME , pmcc4_OSSI_release);if ((rtn =c4hw_attach_all ()))return -rtn;/* installation failure - see system log */ /* housekeeping notifications */ if (log_level != log_level_default)printk (KERN_INFO "%s NOTE: driver parameter <log_level> changed from default %d to %d.\n" , -THIS_MODULE ->name, log_level_default, log_level); +KBUILD_MODNAME , log_level_default, log_level);if (max_mru != max_mru_default)printk (KERN_INFO "%s NOTE: driver parameter <max_mru> changed from default %d to %d.\n" , -THIS_MODULE ->name, max_mru_default, max_mru); +KBUILD_MODNAME , max_mru_default, max_mru);if (max_mtu != max_mtu_default)printk (KERN_INFO "%s NOTE: driver parameter <max_mtu> changed from default %d to %d.\n" , -THIS_MODULE ->name, max_mtu_default, max_mtu); +KBUILD_MODNAME , max_mtu_default, max_mtu);if (max_rxdesc_used != max_rxdesc_default) {if (max_rxdesc_used >2000 ) max_rxdesc_used =2000 ;/* out-of-bounds reset */ printk (KERN_INFO "%s NOTE: driver parameter <max_rxdesc_used> changed from default %d to %d.\n" , -THIS_MODULE ->name, max_rxdesc_default, max_rxdesc_used); +KBUILD_MODNAME , max_rxdesc_default, max_rxdesc_used); }if (max_txdesc_used != max_txdesc_default) {if (max_txdesc_used >1000 ) max_txdesc_used =1000 ;/* out-of-bounds reset */ printk (KERN_INFO "%s NOTE: driver parameter <max_txdesc_used> changed from default %d to %d.\n" , -THIS_MODULE ->name, max_txdesc_default, max_txdesc_used); +KBUILD_MODNAME , max_txdesc_default, max_txdesc_used); }return 0 ;/* installation success */ }
@@ -1331,7 +1331,7 @@ c4_mod_remove (void)cleanup_devs ();c4_cleanup ();cleanup_ioremap (); -printk (KERN_INFO "SBE %s - driver removed.\n" ,THIS_MODULE ->name); +printk (KERN_INFO "SBE %s - driver removed.\n" ,KBUILD_MODNAME ); }module_init (c4_mod_init);
drivers/staging/cxt1e1/sbeproc.c +2 -2
@@ -319,7 +319,7 @@ sbecom_proc_brd_init (ci_t * ci)if (!ci->dir_dev) {printk (KERN_ERR "%s: Unable to create directory /proc/driver/%s\n" , -THIS_MODULE ->name, ci->devname); +KBUILD_MODNAME , ci->devname); goto fail; } e = create_proc_read_entry ("info", S_IFREG | S_IRUGO,
@@ -327,7 +327,7 @@ sbecom_proc_brd_init (ci_t * ci)if (!e) {printk (KERN_ERR "%s: Unable to create entry /proc/driver/%s/info\n" , -THIS_MODULE ->name, ci->devname); +KBUILD_MODNAME , ci->devname); goto fail; }return 0 ;
drivers/staging/cxt1e1/hwprobe.c +5 -4
@@ -230,7 +230,8 @@ c4_hdw_init (struct pci_dev * pdev, int/* our MUSYCC chip supports two functions, 0 & 1 */ if ((fun =PCI_FUNC (pdev->devfn)) >1 ) { -printk (KERN_WARNING "%s: unexpected devfun: 0x%x\n" ,THIS_MODULE ->name, pdev->devfn); +printk (KERN_WARNING "%s: unexpected devfun: 0x%x\n" , +KBUILD_MODNAME , pdev->devfn);return 0 ; }if (pdev->bus)/* obtain bus number */
@@ -260,7 +261,7 @@ c4_hdw_init (struct pci_dev * pdev, int* exceeded */ {printk (KERN_WARNING "%s: exceeded number of allowed devices (>%d)?\n" , -THIS_MODULE ->name,MAX_BOARDS ); +KBUILD_MODNAME ,MAX_BOARDS );return 0 ; }if (pdev->bus)
@@ -282,7 +283,7 @@ c4_hdw_init (struct pci_dev * pdev, int*/ char *cp = hi->devname; -strcpy (cp,THIS_MODULE ->name); +strcpy (cp,KBUILD_MODNAME ); cp +=strlen (cp);/* reposition */ *cp++ ='-' ; *cp++ ='0' + (found /2 );/* there are two found interfaces per
@@ -319,7 +320,7 @@ c4hw_attach_all (void) }if (!found) { -printk (KERN_WARNING "%s: No boards found.\n" ,THIS_MODULE ->name); +printk (KERN_WARNING "%s: No boards found.\n" ,KBUILD_MODNAME );return ENODEV ; }/* sanity check for consistant hardware found */
Re: [PATCH -next] staging: fix cxt1e1 module names
Quoted 4 lines · Randy Dunlap
From: Randy Dunlap <[email protected]>
Lots of cxt1e1 source code uses
THIS_MODULE->name, which won't build whenCONFIG_MODULESis not enabled, so useKBUILD_MODNAMEinstead.
Perhaps a conversion to pr_<level> is better?
--- drivers/staging/cxt1e1/functions.c | 4 ++- drivers/staging/cxt1e1/hwprobe.c | 28 ++++++++++--------- drivers/staging/cxt1e1/linux.c | 38 +++++++++++++------------- drivers/staging/cxt1e1/musycc.c | 13 +++++---- drivers/staging/cxt1e1/pmcc4_drv.c | 16 ++++++----- drivers/staging/cxt1e1/sbecom_inline_linux.h | 2 +- drivers/staging/cxt1e1/sbeproc.c | 8 +++--- 7 files changed, 58 insertions(+), 51 deletions(-)
drivers/staging/cxt1e1/functions.c +3 -1
@@ -11,6 +11,8 @@* GNU General Public License for more details. */ +#define pr_fmt (fmt) KBUILD_MODNAME ": " fmt +#include <linux/slab.h> #include <asm/io.h> #include <asm/byteorder.h>
@@ -117,7 +119,7 @@ watchdog_func (unsigned long arg)if (drvr_state !=SBE_DRVR_AVAILABLE ) {if (log_level >=LOG_MONITOR ) -printk (KERN_WARNING "watchdog_func: drvr not available (%x)\n" , drvr_state); +pr_warning ("%s: drvr not available (%x)\n" , __func__, drvr_state);return ; }#if LINUX_VERSION_CODE <KERNEL_VERSION (2 ,5 ,0 )
drivers/staging/cxt1e1/hwprobe.c +15 -13
@@ -12,6 +12,8 @@* GNU General Public License for more details. */ +#define pr_fmt (fmt) KBUILD_MODNAME ": " fmt +#include <linux/netdevice.h> #include <linux/hdlc.h> #include <linux/if_arp.h>
@@ -230,7 +232,7 @@ c4_hdw_init (struct pci_dev * pdev, int found)/* our MUSYCC chip supports two functions, 0 & 1 */ if ((fun =PCI_FUNC (pdev->devfn)) >1 ) { -printk (KERN_WARNING "%s: unexpected devfun: 0x%x\n" ,THIS_MODULE ->name, pdev->devfn); +pr_warning ("unexpected devfun: 0x%x\n" , pdev->devfn);return 0 ; }if (pdev->bus)/* obtain bus number */
@@ -259,8 +261,7 @@ c4_hdw_init (struct pci_dev * pdev, int found)if (i ==MAX_BOARDS )/* no match in above loop means MAX * exceeded */ { -printk (KERN_WARNING "%s: exceeded number of allowed devices (>%d)?\n" , -THIS_MODULE ->name,MAX_BOARDS ); +pr_warning ("exceeded number of allowed devices (>%d)?\n" ,MAX_BOARDS );return 0 ; }if (pdev->bus)
@@ -319,7 +320,7 @@ c4hw_attach_all (void) }if (!found) { -printk (KERN_WARNING "%s: No boards found.\n" ,THIS_MODULE ->name); +pr_warning ("No boards found\n" );return ENODEV ; }/* sanity check for consistant hardware found */
@@ -327,7 +328,8 @@ c4hw_attach_all (void) {if (hi->pci_slot !=0xff && (!hi->addr[0 ] || !hi->addr[1 ])) { -printk (KERN_WARNING "%s: something very wrong with pci_get_device.\n" , hi->devname); +pr_warning ("%s: something very wrong with pci_get_device\n" , + hi->devname);return EIO ; } }
@@ -340,22 +342,22 @@ c4hw_attach_all (void) {if (request_mem_region (hi->addr[j], hi->len[j], hi->devname) ==0 ) { -printk (KERN_WARNING "%s: memory in use, addr=0x%lx, len=0x%lx ?\n" , - hi->devname, hi->addr[j], hi->len[j]); +pr_warning ("%s: memory in use, addr=0x%lx, len=0x%lx ?\n" , + hi->devname, hi->addr[j], hi->len[j]);cleanup_ioremap ();return ENOMEM ; } hi->addr_mapped[j] = (unsigned long )ioremap (hi->addr[j], hi->len[j]);if (!hi->addr_mapped[j]) { -printk (KERN_WARNING "%s: ioremap fails, addr=0x%lx, len=0x%lx ?\n" , - hi->devname, hi->addr[j], hi->len[j]); +pr_warning ("%s: ioremap fails, addr=0x%lx, len=0x%lx ?\n" , + hi->devname, hi->addr[j], hi->len[j]);cleanup_ioremap ();return ENOMEM ; }#ifdef SBE_MAP_DEBUG -printk (KERN_WARNING "%s: io remapped from phys %x to virt %x\n" , - hi->devname, (u_int32_t ) hi->addr[j], (u_int32_t ) hi->addr_mapped[j]); +pr_warning ("%s: io remapped from phys %x to virt %x\n" , + hi->devname, (u_int32_t ) hi->addr[j], (u_int32_t ) hi->addr_mapped[j]);#endif } }
@@ -371,8 +373,8 @@ c4hw_attach_all (void) pci_enable_device (hi->pdev[1])) { drvr_state =SBE_DRVR_DOWN ; -printk (KERN_WARNING "%s: failed to enable card %d slot %d\n" , - hi->devname, i, hi->pci_slot); +pr_warning ("%s: failed to enable card %d slot %d\n" , + hi->devname, i, hi->pci_slot);cleanup_devs ();cleanup_ioremap ();return EIO ;
drivers/staging/cxt1e1/linux.c +19 -19
@@ -12,6 +12,8 @@* GNU General Public License for more details. */ +#define pr_fmt (fmt) KBUILD_MODNAME ": " fmt +#include <linux/types.h> #include <linux/netdevice.h> #include <linux/hdlc.h>
@@ -563,13 +565,13 @@ create_chan (struct net_device * ndev, ci_t * ci, priv =OS_kmalloc (sizeof (struct c4_priv ));if (!priv) { -printk (KERN_WARNING "%s: no memory for net_device !\n" , ci->devname); +pr_warning ("%s: no memory for net_device !\n" , ci->devname);return 0 ; } dev =alloc_hdlcdev (priv);if (!dev) { -printk (KERN_WARNING "%s: no memory for hdlc_device !\n" , ci->devname); +pr_warning ("%s: no memory for hdlc_device !\n" , ci->devname);OS_kfree (priv);return 0 ; }
@@ -1111,7 +1113,7 @@ c4_add_dev (hdw_info_t * hi, int brdno, unsigned long f0, unsigned long f1, ndev =alloc_netdev (sizeof (ci_t),SBE_IFACETMPL , c4_setup);if (!ndev) { -printk (KERN_WARNING "%s: no memory for struct net_device !\n" , hi->devname); +pr_warning ("%s: no memory for struct net_device !\n" , hi->devname); error_flag =ENOMEM ;return 0 ; }
@@ -1177,8 +1179,7 @@ c4_add_dev (hdw_info_t * hi, int brdno, unsigned long f0, unsigned long f1,#endif ndev->name, ndev)) { -printk (KERN_WARNING "%s: MUSYCC could not get irq: %d\n" , - ndev->name, irq0); +pr_warning ("%s: MUSYCC could not get irq: %d\n" , ndev->name, irq0);unregister_netdev (ndev);OS_kfree (netdev_priv (ndev));OS_kfree (ndev);
@@ -1188,8 +1189,7 @@ c4_add_dev (hdw_info_t * hi, int brdno, unsigned long f0, unsigned long f1,#ifdef CONFIG_SBE_PMCC4_NCOMM if (request_irq (irq1, &c4_ebus_interrupt,IRQF_SHARED , ndev->name, ndev)) { -printk (KERN_WARNING "%s: EBUS could not get irq: %d\n" , - hi->devname, irq1); +pr_warning ("%s: EBUS could not get irq: %d\n" , hi->devname, irq1);unregister_netdev (ndev);free_irq (irq0, ndev);OS_kfree (netdev_priv (ndev));
@@ -1263,33 +1263,33 @@ c4_mod_init (void) {int rtn; -printk (KERN_WARNING "%s: %s\n" ,THIS_MODULE ->name, pmcc4_OSSI_release); +pr_warning ("%s\n" , pmcc4_OSSI_release);if ((rtn =c4hw_attach_all ()))return -rtn;/* installation failure - see system log */ /* housekeeping notifications */ if (log_level != log_level_default) -printk (KERN_INFO "%s NOTE: driver parameter <log_level> changed from default %d to %d.\n" , -THIS_MODULE ->name, log_level_default, log_level); +pr_info ("NOTE: driver parameter <log_level> changed from default %d to %d.\n" , + log_level_default, log_level);if (max_mru != max_mru_default) -printk (KERN_INFO "%s NOTE: driver parameter <max_mru> changed from default %d to %d.\n" , -THIS_MODULE ->name, max_mru_default, max_mru); +pr_info ("NOTE: driver parameter <max_mru> changed from default %d to %d.\n" , + max_mru_default, max_mru);if (max_mtu != max_mtu_default) -printk (KERN_INFO "%s NOTE: driver parameter <max_mtu> changed from default %d to %d.\n" , -THIS_MODULE ->name, max_mtu_default, max_mtu); +pr_info ("NOTE: driver parameter <max_mtu> changed from default %d to %d.\n" , + max_mtu_default, max_mtu);if (max_rxdesc_used != max_rxdesc_default) {if (max_rxdesc_used >2000 ) max_rxdesc_used =2000 ;/* out-of-bounds reset */ -printk (KERN_INFO "%s NOTE: driver parameter <max_rxdesc_used> changed from default %d to %d.\n" , -THIS_MODULE ->name, max_rxdesc_default, max_rxdesc_used); +pr_info ("NOTE: driver parameter <max_rxdesc_used> changed from default %d to %d.\n" , + max_rxdesc_default, max_rxdesc_used); }if (max_txdesc_used != max_txdesc_default) {if (max_txdesc_used >1000 ) max_txdesc_used =1000 ;/* out-of-bounds reset */ -printk (KERN_INFO "%s NOTE: driver parameter <max_txdesc_used> changed from default %d to %d.\n" , -THIS_MODULE ->name, max_txdesc_default, max_txdesc_used); +pr_info ("NOTE: driver parameter <max_txdesc_used> changed from default %d to %d.\n" , + max_txdesc_default, max_txdesc_used); }return 0 ;/* installation success */ }
@@ -1331,7 +1331,7 @@ c4_mod_remove (void)cleanup_devs ();c4_cleanup ();cleanup_ioremap (); -printk (KERN_INFO "SBE %s - driver removed.\n" ,THIS_MODULE ->name); +pr_info ("SBE - driver removed.\n" ); }module_init (c4_mod_init);
drivers/staging/cxt1e1/musycc.c +7 -6
@@ -71,6 +71,7 @@ unsigned int max_bh = 0;char SBEid_pmcc4_musyccc[] ="@(#)musycc.c - $Revision: 2.1 $ (c) Copyright 2004-2006 SBE, Inc." ; +#define pr_fmt (fmt) KBUILD_MODNAME ": " fmt#include <linux/types.h> #include "pmcc4_sysdep.h"
@@ -681,8 +682,8 @@ rewrite: }if (rcnt >MUSYCC_SR_RETRY_CNT ) { -printk (KERN_WARNING "%s: failed service request (#%d)= %x, group %d.\n" , - pi->up->devname,MUSYCC_SR_RETRY_CNT , req, pi->portnum); +pr_warning ("%s: failed service request (#%d)= %x, group %d.\n" , + pi->up->devname,MUSYCC_SR_RETRY_CNT , req, pi->portnum);SD_SEM_GIVE (&pi->sr_sem_busy);/* allow any next request */ return ; }
@@ -959,14 +960,14 @@ musycc_init (ci_t * ci)if (max_mru >0xffe ) { -printk (KERN_WARNING "%s: Maximum allowed MRU exceeded, resetting %d to %d.\n" , -THIS_MODULE ->name, max_mru,0xffe ); +pr_warning ("Maximum allowed MRU exceeded, resetting %d to %d.\n" , + max_mru,0xffe ); max_mru =0xffe ; }if (max_mtu >0xffe ) { -printk (KERN_WARNING "%s: Maximum allowed MTU exceeded, resetting %d to %d.\n" , -THIS_MODULE ->name, max_mtu,0xffe ); +pr_warning ("Maximum allowed MTU exceeded, resetting %d to %d.\n" , + max_mtu,0xffe ); max_mtu =0xffe ; }#ifdef SBE_WAN256T3_ENABLE
drivers/staging/cxt1e1/pmcc4_drv.c +9 -7
@@ -83,6 +83,7 @@char OSSIid_pmcc4_drvc[] ="@(#)pmcc4_drv.c - $Revision: 3.1 $ (c) Copyright 2002-2007 One Stop Systems, Inc." ; +#define pr_fmt (fmt) KBUILD_MODNAME ": " fmt#if defined (__FreeBSD__) || defined (__NetBSD__)#include <sys/param.h>
@@ -207,8 +208,8 @@ c4_new (void *hi)ci_t *ci;#ifdef SBE_MAP_DEBUG -printk (KERN_WARNING "%s: c4_new() entered, ci needs %u.\n" , -THIS_MODULE ->name, (unsigned int )sizeof (ci_t)); +pr_warning ("c4_new() entered, ci needs %u.\n" , + (unsigned int )sizeof (ci_t));#endif ci = (ci_t *)OS_kmalloc (sizeof (ci_t));
@@ -220,8 +221,8 @@ c4_new (void *hi) c4_list = ci; ci->brdno = ci->next ? ci->next->brdno +1 :0 ; }else -printk (KERN_WARNING "%s: failed CI malloc, size %u.\n" , -THIS_MODULE ->name, (unsigned int )sizeof (ci_t)); +pr_warning ("failed CI malloc, size %u.\n" , + (unsigned int )sizeof (ci_t));if (CI ==0 )CI = ci;/* DEBUG, only board 0 usage */
@@ -805,7 +806,8 @@ c4_init (ci_t * ci, u_char *func0, u_char *func1)break ;default : ci->max_port =0 ; -printk (KERN_WARNING "%s: illegal port configuration (%x)\n" , ci->devname, pmsk); +pr_warning ("%s: illegal port configuration (%x)\n" , + ci->devname, pmsk);return SBE_DRVR_FAIL ; }#ifdef SBE_MAP_DEBUG
@@ -847,8 +849,8 @@ c4_init (ci_t * ci, u_char *func0, u_char *func1) ch->p.mode_56k =0 ;/* default is 64kbps mode */ }else { -printk (KERN_WARNING "%s: failed mch_t malloc, port %d channel %d size %u.\n" , -THIS_MODULE ->name, portnum, j, (unsigned int )sizeof (mch_t)); +pr_warning ("failed mch_t malloc, port %d channel %d size %u.\n" , + portnum, j, (unsigned int )sizeof (mch_t));break ; } }
drivers/staging/cxt1e1/sbecom_inline_linux.h +1 -1
@@ -164,7 +164,7 @@ OS_mem_token_alloc (size_t size) skb =dev_alloc_skb (size);if (!skb) { -//printk (KERN_WARNING "no mem in OS_mem_token_alloc !"); +//pr_warning("no mem in OS_mem_token_alloc !\n"); return 0 ; }return skb;
drivers/staging/cxt1e1/sbeproc.c +4 -4
@@ -11,6 +11,8 @@* GNU General Public License for more details. */ +#define pr_fmt (fmt) KBUILD_MODNAME ": " fmt +#include <linux/types.h> #include <linux/module.h> #include <linux/errno.h>
@@ -318,16 +320,14 @@ sbecom_proc_brd_init (ci_t * ci) ci->dir_dev =proc_mkdir (dir,NULL );if (!ci->dir_dev) { -printk (KERN_ERR "%s: Unable to create directory /proc/driver/%s\n" , -THIS_MODULE ->name, ci->devname); +pr_err ("Unable to create directory /proc/driver/%s\n" , ci->devname); goto fail; } e =create_proc_read_entry ("info" ,S_IFREG |S_IRUGO , ci->dir_dev, sbecom_proc_get_sbe_info, ci);if (!e) { -printk (KERN_ERR "%s: Unable to create entry /proc/driver/%s/info\n" , -THIS_MODULE ->name, ci->devname); +pr_err ("Unable to create entry /proc/driver/%s/info\n" , ci->devname); goto fail; }return 0 ;
Re: [PATCH -next] staging: fix cxt1e1 module names
Quoted 7 lines · On Mon, 03 May 2010 11:02:44 -0700 Joe Perches wrote:
Quoted 4 lines · Randy Dunlap
From: Randy Dunlap <[email protected]>
Lots of cxt1e1 source code uses
THIS_MODULE->name, which won't build whenCONFIG_MODULESis not enabled, so useKBUILD_MODNAMEinstead.Perhaps a conversion to pr_<level> is better?
Sure, fine with me. Thanks.
---
~Randy
*** Remember to use Documentation/SubmitChecklist when testing your code ***
Re: [PATCH -next] staging/cxt1e1: Convert bare printks to pr_<level>
Added #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
A few line splits for long arguments
A couple of embedded function names converted to "%s", __func__ Removed some uses of THIS_MODULE->name
--- drivers/staging/cxt1e1/comet.c | 8 +- drivers/staging/cxt1e1/functions.c | 4 +- drivers/staging/cxt1e1/hwprobe.c | 22 ++-- drivers/staging/cxt1e1/linux.c | 28 ++-- drivers/staging/cxt1e1/musycc.c | 128 +++++++++--------- drivers/staging/cxt1e1/pmc93x6_eeprom.c | 12 +- drivers/staging/cxt1e1/pmcc4_drv.c | 183 +++++++++++++------------- drivers/staging/cxt1e1/sbecom_inline_linux.h | 4 +- drivers/staging/cxt1e1/sbeproc.c | 6 +- 9 files changed, 204 insertions(+), 191 deletions(-)
drivers/staging/cxt1e1/comet.c +5 -3
@@ -11,6 +11,8 @@* GNU General Public License for more details. */ +#define pr_fmt (fmt) KBUILD_MODNAME ": " fmt +#include <asm/io.h> #include <linux/hdlc.h> #include "pmcc4_sysdep.h"
@@ -291,12 +293,12 @@ init_comet (void *ci, comet_t * comet, u_int32_t port_mode, int clockmaster,if ((moreParams &CFG_CLK_PORT_MASK ) ==CFG_CLK_PORT_INTERNAL ) {if (log_level >=LOG_SBEBUG12 ) -printk (">> init_comet: clockmaster internal clock\n" ); +pr_info (">> %s: clockmaster internal clock\n" , __func__);pci_write_32 ((u_int32_t *) &comet->tx_time,0x0d );/* internal oscillator */ }else /* external clock source */ {if (log_level >=LOG_SBEBUG12 ) -printk (">> init_comet: clockmaster external clock\n" ); +pr_info (">> %s: clockmaster external clock\n" , __func__);pci_write_32 ((u_int32_t *) &comet->tx_time,0x09 );/* loop timing * (external) */ }
@@ -311,7 +313,7 @@ init_comet (void *ci, comet_t * comet, u_int32_t port_mode, int clockmaster,pci_write_32 ((u_int32_t *) &comet->brif_fpcfg,0x20 );/* Slave Mode i.e. * FPMODE=1 (@0x20) */ if (log_level >=LOG_SBEBUG12 ) -printk (">> init_comet: clockslave internal clock\n" ); +pr_info (">> %s: clockslave internal clock\n" , __func__);pci_write_32 ((u_int32_t *) &comet->tx_time,0x0d );/* oscillator timing */ }
drivers/staging/cxt1e1/functions.c +2 -2
@@ -68,7 +68,7 @@ pci_read_32 (u_int32_t *p)FLUSH_PCI_READ (); v =le32_to_cpu (*p);if (log_level >=LOG_DEBUG ) -printk ("pci_read : %x = %x\n" , (u_int32_t ) p, v); +pr_info ("pci_read : %x = %x\n" , (u_int32_t ) p, v);return v;#else FLUSH_PCI_READ ();/* */
@@ -81,7 +81,7 @@ pci_write_32 (u_int32_t *p, u_int32_t v) {#ifdef FLOW_DEBUG if (log_level >=LOG_DEBUG ) -printk ("pci_write: %x = %x\n" , (u_int32_t ) p, v); +pr_info ("pci_write: %x = %x\n" , (u_int32_t ) p, v);#endif *p =cpu_to_le32 (v);FLUSH_PCI_WRITE ();/* This routine is called from routines
drivers/staging/cxt1e1/hwprobe.c +11 -11
@@ -83,17 +83,17 @@ show_two (hdw_info_t * hi, int brdno) (sn[5 ] &0x0000ff ), (u_int8_t) hi->revid[0]); -printk ("%s\n" , banner); +pr_info ("%s\n" , banner); pdev = hi->pdev[0 ]; -printk ("%s: %s at v/p=%lx/%lx (%02x:%02x.%x) irq %d\n" , +pr_info ("%s: %s at v/p=%lx/%lx (%02x:%02x.%x) irq %d\n" , hi->devname,"MUSYCC" , (unsigned long ) hi->addr_mapped[0 ], hi->addr[0 ], hi->pci_busno, (u_int8_t )PCI_SLOT (pdev->devfn), (u_int8_t )PCI_FUNC (pdev->devfn), pdev->irq); pdev = hi->pdev[1 ]; - printk ("%s: %s at v/p=%lx/%lx (%02x:%02x.%x) irq %d\n", + pr_info("%s: %s at v/p=%lx/%lx (%02x:%02x.%x) irq %d\n", hi->devname, "EBUS ", (unsigned long) hi->addr_mapped[1], hi->addr[1], hi->pci_busno, (u_int8_t) PCI_SLOT (pdev->devfn),
@@ -116,22 +116,22 @@ hdw_sn_get (hdw_info_t * hi, int brdno) {unsigned char *ucp = (unsigned char *) &hi->mfg_info.data; -printk ("eeprom[00]: %02x %02x %02x %02x %02x %02x %02x %02x\n" , +pr_info ("eeprom[00]: %02x %02x %02x %02x %02x %02x %02x %02x\n" , *(ucp +0 ), *(ucp +1 ), *(ucp +2 ), *(ucp +3 ), *(ucp +4 ), *(ucp +5 ), *(ucp +6 ), *(ucp +7 )); -printk ("eeprom[08]: %02x %02x %02x %02x %02x %02x %02x %02x\n" , +pr_info ("eeprom[08]: %02x %02x %02x %02x %02x %02x %02x %02x\n" , *(ucp +8 ), *(ucp +9 ), *(ucp +10 ), *(ucp +11 ), *(ucp +12 ), *(ucp +13 ), *(ucp +14 ), *(ucp +15 )); -printk ("eeprom[16]: %02x %02x %02x %02x %02x %02x %02x %02x\n" , +pr_info ("eeprom[16]: %02x %02x %02x %02x %02x %02x %02x %02x\n" , *(ucp +16 ), *(ucp +17 ), *(ucp +18 ), *(ucp +19 ), *(ucp +20 ), *(ucp +21 ), *(ucp +22 ), *(ucp +23 )); -printk ("eeprom[24]: %02x %02x %02x %02x %02x %02x %02x %02x\n" , +pr_info ("eeprom[24]: %02x %02x %02x %02x %02x %02x %02x %02x\n" , *(ucp +24 ), *(ucp +25 ), *(ucp +26 ), *(ucp +27 ), *(ucp +28 ), *(ucp +29 ), *(ucp +30 ), *(ucp +31 )); -printk ("eeprom[32]: %02x %02x %02x %02x %02x %02x %02x %02x\n" , +pr_info ("eeprom[32]: %02x %02x %02x %02x %02x %02x %02x %02x\n" , *(ucp +32 ), *(ucp +33 ), *(ucp +34 ), *(ucp +35 ), *(ucp +36 ), *(ucp +37 ), *(ucp +38 ), *(ucp +39 )); -printk ("eeprom[40]: %02x %02x %02x %02x %02x %02x %02x %02x\n" , +pr_info ("eeprom[40]: %02x %02x %02x %02x %02x %02x %02x %02x\n" , *(ucp +40 ), *(ucp +41 ), *(ucp +42 ), *(ucp +43 ), *(ucp +44 ), *(ucp +45 ), *(ucp +46 ), *(ucp +47 )); }#endif #if 0 - printk ("sn: %x %x %x %x %x %x\n", + pr_info("sn: %x %x %x %x %x %x\n", hi->mfg_info.Serial[0], hi->mfg_info.Serial[1], hi->mfg_info.Serial[2],
@@ -144,7 +144,7 @@ hdw_sn_get (hdw_info_t * hi, int brdno) {/* bad crc, data is suspect */ if (log_level >=LOG_WARN ) -printk ("%s: EEPROM cksum error\n" , hi->devname); +pr_info ("%s: EEPROM cksum error\n" , hi->devname); hi->mfg_info_sts =EEPROM_CRCERR ; } else hi->mfg_info_sts = EEPROM_OK;
drivers/staging/cxt1e1/linux.c +15 -13
@@ -195,7 +195,8 @@ c4_wk_chan_restart (mch_t * ch)mpi_t *pi = ch->up;#ifdef RLD_RESTART_DEBUG -printk (">> c4_wk_chan_restart: queueing Port %d Chan %d, mch_t @ %p\n" , pi->portnum, ch->channum, ch); +pr_info (">> %s: queueing Port %d Chan %d, mch_t @ %p\n" , + __func__, pi->portnum, ch->channum, ch);#endif /* create new entry w/in workqueue for this channel and let'er rip */
@@ -236,7 +237,8 @@ c4_wq_port_init (mpi_t * pi)sprintf (np,"%s%d" , pi->up->devname, pi->portnum);/* IE pmcc4-01) */ #ifdef RLD_RESTART_DEBUG -printk (">> c4_wq_port_init: creating workqueue <%s> for Port %d.\n" , name, pi->portnum);/* RLD DEBUG */ +pr_info (">> %s: creating workqueue <%s> for Port %d.\n" , + __func__, name, pi->portnum);/* RLD DEBUG */ #endif if (!(pi->wq_port =create_singlethread_workqueue (name)))return ENOMEM ;
@@ -284,7 +286,7 @@ c4_ebus_interrupt (int irq, void *dev_instance)static int void_open (struct net_device * ndev) { -printk ("%s: trying to open master device !\n" , ndev->name); +pr_info ("%s: trying to open master device !\n" , ndev->name);return -1 ; }
@@ -317,7 +319,7 @@ chan_open (struct net_device * ndev) hdlc->proto =IF_PROTO_HDLC ;if ((ret =hdlc_open (hdlc))) { -printk ("%s: hdlc_open failure, err %d.\n" ,THIS_MODULE ->name, ret); +pr_info ("hdlc_open failure, err %d.\n" , ret);return ret; }if ((ret =c4_chan_up (DEV_TO_PRIV (hdlc)->ci,DEV_TO_PRIV (hdlc)->channum)))
@@ -340,7 +342,7 @@ chan_open (struct net_device * ndev)if ((ret =hdlc_open (ndev))) { -printk ("%s: hdlc_open failure, err %d.\n" ,THIS_MODULE ->name, ret); +pr_info ("hdlc_open failure, err %d.\n" , ret);return ret; }if ((ret =c4_chan_up (priv->ci, priv->channum)))
@@ -629,7 +631,7 @@ create_chan (struct net_device * ndev, ci_t * ci,if (ret) {if (log_level >=LOG_WARN ) -printk ("%s: create_chan[%d] registration error = %d.\n" , +pr_info ("%s: create_chan[%d] registration error = %d.\n" , ci->devname, cp->channum, ret);free_netdev (dev);/* cleanup */ return 0 ;/* failed to register */
@@ -1018,7 +1020,7 @@ c4_ioctl (struct net_device * ndev, struct ifreq * ifr, int cmd)#endif #if 0 -printk ("c4_ioctl: iocmd %x, dir %x type %x nr %x iolen %d.\n" , iocmd, +pr_info ("c4_ioctl: iocmd %x, dir %x type %x nr %x iolen %d.\n" , iocmd,_IOC_DIR (iocmd),_IOC_TYPE (iocmd),_IOC_NR (iocmd),_IOC_SIZE (iocmd));#endif
@@ -1031,23 +1033,23 @@ c4_ioctl (struct net_device * ndev, struct ifreq * ifr, int cmd)switch (iocmd) {case SBE_IOC_PORT_GET : -//printk (">> SBE_IOC_PORT_GET Ioctl...\n"); +//pr_info(">> SBE_IOC_PORT_GET Ioctl...\n"); ret =do_get_port (ndev, data);break ;case SBE_IOC_PORT_SET : -//printk (">> SBE_IOC_PORT_SET Ioctl...\n"); +//pr_info(">> SBE_IOC_PORT_SET Ioctl...\n"); ret =do_set_port (ndev, data);break ;case SBE_IOC_CHAN_GET : -//printk (">> SBE_IOC_CHAN_GET Ioctl...\n"); +//pr_info(">> SBE_IOC_CHAN_GET Ioctl...\n"); ret =do_get_chan (ndev, data);break ;case SBE_IOC_CHAN_SET : -//printk (">> SBE_IOC_CHAN_SET Ioctl...\n"); +//pr_info(">> SBE_IOC_CHAN_SET Ioctl...\n"); ret =do_set_chan (ndev, data);break ;case C4_DEL_CHAN : -//printk (">> C4_DEL_CHAN Ioctl...\n"); +//pr_info(">> C4_DEL_CHAN Ioctl...\n"); ret =do_del_chan (ndev, data);break ;case SBE_IOC_CHAN_NEW :
@@ -1084,7 +1086,7 @@ c4_ioctl (struct net_device * ndev, struct ifreq * ifr, int cmd)return -EFAULT ;break ;default : -//printk (">> c4_ioctl: EINVAL - unknown iocmd <%x>\n", iocmd); +//pr_info(">> c4_ioctl: EINVAL - unknown iocmd <%x>\n", iocmd); ret = -EINVAL ;break ; }
drivers/staging/cxt1e1/musycc.c +66 -62
445 lines not on this page · raw message
drivers/staging/cxt1e1/pmc93x6_eeprom.c +7 -5
@@ -21,6 +21,8 @@* GNU General Public License for more details. */ +#define pr_fmt (fmt) KBUILD_MODNAME ": " fmt +#include <linux/types.h> #include "pmcc4_sysdep.h" #include "sbecom_inline_linux.h"
@@ -448,7 +450,7 @@ pmcCalcCrc_T01 (void *bufp) (u_int32_t *) &crc);#ifdef EEPROM_TYPE_DEBUG -printk ("sbeCrc: crc 1 calculated as %08x\n" , crc);/* RLD DEBUG */ +pr_info ("sbeCrc: crc 1 calculated as %08x\n" , crc);/* RLD DEBUG */ #endif return ~crc; }
@@ -474,7 +476,7 @@ pmcCalcCrc_T02 (void *bufp) (u_int32_t *) &crc);#ifdef EEPROM_TYPE_DEBUG -printk ("sbeCrc: crc 2 calculated as %08x\n" , crc);/* RLD DEBUG */ +pr_info ("sbeCrc: crc 2 calculated as %08x\n" , crc);/* RLD DEBUG */ #endif return crc; }
@@ -520,7 +522,7 @@ pmc_init_seeprom (u_int32_t addr, u_int32_t serialNum)#ifdef DEBUG for (i =0 ; i <sizeof (FLD_TYPE2 ); ++i) -printk ("[%02X] = %02X\n" , i, buffer.bytes[i] &0xFF ); +pr_info ("[%02X] = %02X\n" , i, buffer.bytes[i] &0xFF );#endif /* Write structure to serial EEPROM */
@@ -538,7 +540,7 @@ pmc_verify_cksum (void *bufp)/* Retrieve contents of CRC field */ crc1 =pmcGetBuffValue (&buf1->Crc32[0 ],sizeof (buf1->Crc32));#ifdef EEPROM_TYPE_DEBUG -printk ("EEPROM: chksum 1 reads as %08x\n" , crc1);/* RLD DEBUG */ +pr_info ("EEPROM: chksum 1 reads as %08x\n" , crc1);/* RLD DEBUG */ #endif if ((buf1->type ==PROM_FORMAT_TYPE1 ) && (pmcCalcCrc_T01 ((void *) buf1) == crc1))
@@ -546,7 +548,7 @@ pmc_verify_cksum (void *bufp) crc2 =pmcGetBuffValue (&buf2->Crc32[0 ],sizeof (buf2->Crc32));#ifdef EEPROM_TYPE_DEBUG -printk ("EEPROM: chksum 2 reads as %08x\n" , crc2);/* RLD DEBUG */ +pr_info ("EEPROM: chksum 2 reads as %08x\n" , crc2);/* RLD DEBUG */ #endif if ((buf2->type ==PROM_FORMAT_TYPE2 ) && (pmcCalcCrc_T02 ((void *) buf2) == crc2))
drivers/staging/cxt1e1/pmcc4_drv.c +93 -90
427 lines not on this page · raw message
drivers/staging/cxt1e1/sbecom_inline_linux.h +2 -2
@@ -94,7 +94,7 @@ pci_read_32 (u_int32_t *p)FLUSH_PCI_READ (); v =le32_to_cpu (*p);if (log_level >=LOG_DEBUG ) -printk ("pci_read : %x = %x\n" , (u_int32_t ) p, v); +pr_info ("pci_read : %x = %x\n" , (u_int32_t ) p, v);return v;#else FLUSH_PCI_READ ();/* */
@@ -107,7 +107,7 @@ pci_write_32 (u_int32_t *p, u_int32_t v) {#ifdef FLOW_DEBUG if (log_level >=LOG_DEBUG ) -printk ("pci_write: %x = %x\n" , (u_int32_t ) p, v); +pr_info ("pci_write: %x = %x\n" , (u_int32_t ) p, v);#endif *p =cpu_to_le32 (v);FLUSH_PCI_WRITE ();/* This routine is called from routines
drivers/staging/cxt1e1/sbeproc.c +3 -3
@@ -66,7 +66,7 @@ sbecom_proc_get_sbe_info (char *buffer, char **start, off_t offset, }#if 0 /** RLD DEBUG **/ -printk (">> sbecom_proc_get_sbe_info: entered, offset %d. length %d.\n" , +pr_info (">> sbecom_proc_get_sbe_info: entered, offset %d. length %d.\n" , (int ) offset, (int ) length);#endif
@@ -90,7 +90,7 @@ sbecom_proc_get_sbe_info (char *buffer, char **start, off_t offset,#if 0 /** RLD DEBUG **/ -printk (">> sbecom_get_brdinfo: returned, first_if %p <%s> last_if %p <%s>\n" , +pr_info (">> sbecom_get_brdinfo: returned, first_if %p <%s> last_if %p <%s>\n" , (char *) &bip->first_iname, (char *) &bip->first_iname, (char *) &bip->last_iname, (char *) &bip->last_iname);#endif
@@ -293,7 +293,7 @@ sbecom_proc_get_sbe_info (char *buffer, char **start, off_t offset,#endif #if 0 -printk (">> proc_fs: returned len = %d., start %p\n" , len, start);/* RLD DEBUG */ +pr_info (">> proc_fs: returned len = %d., start %p\n" , len, start);/* RLD DEBUG */ #endif /***
Re: [PATCH -next] staging/cxt1e1: Convert bare printks to pr_<level>
Am Montag 03 Mai 2010 21:33:16 schrieb Joe Perches:
Quoted 6 lines
Added #define
pr_fmt(fmt)KBUILD_MODNAME": " fmt
A few line splits for long arguments
A couple of embedded function names converted to "%s",__func__Removed some uses ofTHIS_MODULE->nameSigned-off-by Joe Perches <[email protected]>
Hi,
I applied Joe's patch, but unfortunately it misses out one part of Randy's original patch, i.e. the conversion in line 286 of hwprobe.c.
Joe: Can you perhaps add this to your patch?
Thanks,
Peter
---
Copied from original Patch by Randy dunlap
drivers/staging/cxt1e1/hwprobe.c +1 -1
@@ -282,7 +283,7 @@ c4_hdw_init (struct pci_dev * pdev, int*/ char *cp = hi->devname; -strcpy (cp,THIS_MODULE ->name); +strcpy (cp,KBUILD_MODNAME ); cp +=strlen (cp);/* reposition */ *cp++ ='-' ; *cp++ ='0' + (found /2 );/* there are two found interfaces per
Re: [PATCH -next] staging/cxt1e1: Convert bare printks to pr_<level>
Quoted 6 lines · Peter Hüwe
Am Montag 03 Mai 2010 21:33:16 schrieb Joe Perches:
Quoted 5 lines
Added #define
pr_fmt(fmt)KBUILD_MODNAME": " fmt
A few line splits for long arguments
A couple of embedded function names converted to "%s",__func__Removed some uses ofTHIS_MODULE->name
Quoted 7 lines
Quoted 1 line
Signed-off-by Joe Perches <[email protected]>Hi,
I applied Joe's patch, but unfortunately it misses out one part of Randy's original patch, i.e. the conversion in line 286 ofhwprobe.c.Joe: Can you perhaps add this to your patch?
I've already applied Joe's patch, so I'll queue up yours as well.
thanks,
greg k-h