]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/commitdiff
fs: replace remaining __FUNCTION__ occurrences
authorHarvey Harrison <harvey.harrison@gmail.com>
Wed, 30 Apr 2008 07:55:09 +0000 (00:55 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Wed, 30 Apr 2008 15:29:54 +0000 (08:29 -0700)
__FUNCTION__ is gcc-specific, use __func__

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
28 files changed:
fs/adfs/adfs.h
fs/autofs4/autofs_i.h
fs/bfs/bfs.h
fs/buffer.c
fs/configfs/file.c
fs/configfs/mount.c
fs/configfs/symlink.c
fs/dlm/lockspace.c
fs/exportfs/expfs.c
fs/fat/cache.c
fs/fat/fatent.c
fs/fat/file.c
fs/gfs2/locking/dlm/sysfs.c
fs/gfs2/util.h
fs/jffs2/debug.h
fs/jffs2/xattr.c
fs/lockd/clntproc.c
fs/lockd/svclock.c
fs/msdos/namei.c
fs/namespace.c
fs/nfsd/nfs4callback.c
fs/ntfs/debug.h
fs/partitions/ldm.c
fs/smbfs/smb_debug.h
fs/sysfs/file.c
fs/sysfs/mount.c
fs/udf/super.c
fs/vfat/namei.c

index 936f2af39c433e12dfb8966b8716c3a90d7f1d2c..831157502d5ae58a25bcec65c9af58d5eabc871f 100644 (file)
@@ -75,7 +75,7 @@ extern unsigned int adfs_map_free(struct super_block *sb);
 /* Misc */
 void __adfs_error(struct super_block *sb, const char *function,
                  const char *fmt, ...);
-#define adfs_error(sb, fmt...) __adfs_error(sb, __FUNCTION__, fmt)
+#define adfs_error(sb, fmt...) __adfs_error(sb, __func__, fmt)
 
 /* super.c */
 
index 2d4ae40718d9ecdc35119a82a10d264ce5c178ea..c3d352d7fa9304cb44c6ec4e4542bbc46f8ec2b2 100644 (file)
@@ -35,7 +35,7 @@
 /* #define DEBUG */
 
 #ifdef DEBUG
-#define DPRINTK(fmt,args...) do { printk(KERN_DEBUG "pid %d: %s: " fmt "\n" , current->pid , __FUNCTION__ , ##args); } while(0)
+#define DPRINTK(fmt,args...) do { printk(KERN_DEBUG "pid %d: %s: " fmt "\n" , current->pid , __func__ , ##args); } while(0)
 #else
 #define DPRINTK(fmt,args...) do {} while(0)
 #endif
index 71faf4d2390824ac2f0e001c32bb24c126f7f653..70f5d3a8eede460af9faf2f6e45407cc01f7d086 100644 (file)
@@ -42,7 +42,7 @@ static inline struct bfs_inode_info *BFS_I(struct inode *inode)
 
 
 #define printf(format, args...) \
-       printk(KERN_ERR "BFS-fs: %s(): " format, __FUNCTION__, ## args)
+       printk(KERN_ERR "BFS-fs: %s(): " format, __func__, ## args)
 
 /* inode.c */
 extern struct inode *bfs_iget(struct super_block *sb, unsigned long ino);
index 189efa4efc6ede2d5b9e5c3703f4004abe9655e6..a073f3f4f013c5c349afede7edb715672bfd4928 100644 (file)
@@ -1101,7 +1101,7 @@ grow_buffers(struct block_device *bdev, sector_t block, int size)
 
                printk(KERN_ERR "%s: requested out-of-range block %llu for "
                        "device %s\n",
-                       __FUNCTION__, (unsigned long long)block,
+                       __func__, (unsigned long long)block,
                        bdevname(bdev, b));
                return -EIO;
        }
index 397cb503a180da62a9cbcdc2f0aeb86b81851cc6..2b6cb23dd14e99a4165af595a1f6670e002d8d3b 100644 (file)
@@ -115,7 +115,7 @@ configfs_read_file(struct file *file, char __user *buf, size_t count, loff_t *pp
                        goto out;
        }
        pr_debug("%s: count = %zd, ppos = %lld, buf = %s\n",
-                __FUNCTION__, count, *ppos, buffer->page);
+                __func__, count, *ppos, buffer->page);
        retval = simple_read_from_buffer(buf, count, ppos, buffer->page,
                                         buffer->count);
 out:
index de3b31d0a37d88a44185cb6be1efeefed6bc1cab..8421cea7d8c7b1460b0cfdf90e831a3012ddf803 100644 (file)
@@ -92,7 +92,7 @@ static int configfs_fill_super(struct super_block *sb, void *data, int silent)
 
        root = d_alloc_root(inode);
        if (!root) {
-               pr_debug("%s: could not get root dentry!\n",__FUNCTION__);
+               pr_debug("%s: could not get root dentry!\n",__func__);
                iput(inode);
                return -ENOMEM;
        }
index 78929ea84ff2da08688619b2b83d74700ca0dc25..2a731ef5f305c3bdd803937a3d893997a2ca6361 100644 (file)
@@ -210,13 +210,13 @@ static int configfs_get_target_path(struct config_item * item, struct config_ite
        if (size > PATH_MAX)
                return -ENAMETOOLONG;
 
-       pr_debug("%s: depth = %d, size = %d\n", __FUNCTION__, depth, size);
+       pr_debug("%s: depth = %d, size = %d\n", __func__, depth, size);
 
        for (s = path; depth--; s += 3)
                strcpy(s,"../");
 
        fill_item_path(target, path, size);
-       pr_debug("%s: path = '%s'\n", __FUNCTION__, path);
+       pr_debug("%s: path = '%s'\n", __func__, path);
 
        return 0;
 }
index b64e55e0515d058d6884e9408b9e7fb0580e443d..499e16759e96fea13329dc05d5408194fa96e4e9 100644 (file)
@@ -200,7 +200,7 @@ int __init dlm_lockspace_init(void)
 
        dlm_kset = kset_create_and_add("dlm", NULL, kernel_kobj);
        if (!dlm_kset) {
-               printk(KERN_WARNING "%s: can not create kset\n", __FUNCTION__);
+               printk(KERN_WARNING "%s: can not create kset\n", __func__);
                return -ENOMEM;
        }
        return 0;
index 109ab5e44eca3f6d5961f721b582d137779c6265..cc91227d3bb88dcdce06b83806baf6dd7f912225 100644 (file)
@@ -150,12 +150,12 @@ reconnect_path(struct vfsmount *mnt, struct dentry *target_dir)
                        if (IS_ERR(ppd)) {
                                err = PTR_ERR(ppd);
                                dprintk("%s: get_parent of %ld failed, err %d\n",
-                                       __FUNCTION__, pd->d_inode->i_ino, err);
+                                       __func__, pd->d_inode->i_ino, err);
                                dput(pd);
                                break;
                        }
 
-                       dprintk("%s: find name of %lu in %lu\n", __FUNCTION__,
+                       dprintk("%s: find name of %lu in %lu\n", __func__,
                                pd->d_inode->i_ino, ppd->d_inode->i_ino);
                        err = exportfs_get_name(mnt, ppd, nbuf, pd);
                        if (err) {
@@ -168,14 +168,14 @@ reconnect_path(struct vfsmount *mnt, struct dentry *target_dir)
                                        continue;
                                break;
                        }
-                       dprintk("%s: found name: %s\n", __FUNCTION__, nbuf);
+                       dprintk("%s: found name: %s\n", __func__, nbuf);
                        mutex_lock(&ppd->d_inode->i_mutex);
                        npd = lookup_one_len(nbuf, ppd, strlen(nbuf));
                        mutex_unlock(&ppd->d_inode->i_mutex);
                        if (IS_ERR(npd)) {
                                err = PTR_ERR(npd);
                                dprintk("%s: lookup failed: %d\n",
-                                       __FUNCTION__, err);
+                                       __func__, err);
                                dput(ppd);
                                dput(pd);
                                break;
@@ -188,7 +188,7 @@ reconnect_path(struct vfsmount *mnt, struct dentry *target_dir)
                        if (npd == pd)
                                noprogress = 0;
                        else
-                               printk("%s: npd != pd\n", __FUNCTION__);
+                               printk("%s: npd != pd\n", __func__);
                        dput(npd);
                        dput(ppd);
                        if (IS_ROOT(pd)) {
index 639b3b4f86d15a8a17a331a3fabdbb16d0bc8048..fda25479af26720690969dde01f444d8bc730f07 100644 (file)
@@ -242,7 +242,7 @@ int fat_get_cluster(struct inode *inode, int cluster, int *fclus, int *dclus)
                /* prevent the infinite loop of cluster chain */
                if (*fclus > limit) {
                        fat_fs_panic(sb, "%s: detected the cluster chain loop"
-                                    " (i_pos %lld)", __FUNCTION__,
+                                    " (i_pos %lld)", __func__,
                                     MSDOS_I(inode)->i_pos);
                        nr = -EIO;
                        goto out;
@@ -253,7 +253,7 @@ int fat_get_cluster(struct inode *inode, int cluster, int *fclus, int *dclus)
                        goto out;
                else if (nr == FAT_ENT_FREE) {
                        fat_fs_panic(sb, "%s: invalid cluster chain"
-                                    " (i_pos %lld)", __FUNCTION__,
+                                    " (i_pos %lld)", __func__,
                                     MSDOS_I(inode)->i_pos);
                        nr = -EIO;
                        goto out;
@@ -286,7 +286,7 @@ static int fat_bmap_cluster(struct inode *inode, int cluster)
                return ret;
        else if (ret == FAT_ENT_EOF) {
                fat_fs_panic(sb, "%s: request beyond EOF (i_pos %lld)",
-                            __FUNCTION__, MSDOS_I(inode)->i_pos);
+                            __func__, MSDOS_I(inode)->i_pos);
                return -EIO;
        }
        return dclus;
index 13ab763cc5109addcb1b79448e37826a58cdf795..302e95c4af7e0c517704d987932411066c129d86 100644 (file)
@@ -546,7 +546,7 @@ int fat_free_clusters(struct inode *inode, int cluster)
                        goto error;
                } else if (cluster == FAT_ENT_FREE) {
                        fat_fs_panic(sb, "%s: deleting FAT entry beyond EOF",
-                                    __FUNCTION__);
+                                    __func__);
                        err = -EIO;
                        goto error;
                }
index d604bb132422450ccce7248df845b455721b6aa0..27cc1164ec36baa84284836686d1603a36451423 100644 (file)
@@ -208,7 +208,7 @@ static int fat_free(struct inode *inode, int skip)
                } else if (ret == FAT_ENT_FREE) {
                        fat_fs_panic(sb,
                                     "%s: invalid cluster chain (i_pos %lld)",
-                                    __FUNCTION__, MSDOS_I(inode)->i_pos);
+                                    __func__, MSDOS_I(inode)->i_pos);
                        ret = -EIO;
                } else if (ret > 0) {
                        err = fat_ent_write(inode, &fatent, FAT_ENT_EOF, wait);
index 8479da47049cbe163c8d642c1cbc8fe30532ee39..a4ff271df9ee4432eb52ceb16f59cb65a0af1f87 100644 (file)
@@ -212,7 +212,7 @@ int gdlm_sysfs_init(void)
 {
        gdlm_kset = kset_create_and_add("lock_dlm", NULL, kernel_kobj);
        if (!gdlm_kset) {
-               printk(KERN_WARNING "%s: can not create kset\n", __FUNCTION__);
+               printk(KERN_WARNING "%s: can not create kset\n", __func__);
                return -ENOMEM;
        }
        return 0;
index 509c5d60bd803ecc928df4aad578eb8856ae9ffa..7f48576289c9f9a916aee237d6b2d6308f2bb93b 100644 (file)
@@ -41,7 +41,7 @@ int gfs2_assert_withdraw_i(struct gfs2_sbd *sdp, char *assertion,
 
 #define gfs2_assert_withdraw(sdp, assertion) \
 ((likely(assertion)) ? 0 : gfs2_assert_withdraw_i((sdp), #assertion, \
-                                       __FUNCTION__, __FILE__, __LINE__))
+                                       __func__, __FILE__, __LINE__))
 
 
 int gfs2_assert_warn_i(struct gfs2_sbd *sdp, char *assertion,
@@ -49,28 +49,28 @@ int gfs2_assert_warn_i(struct gfs2_sbd *sdp, char *assertion,
 
 #define gfs2_assert_warn(sdp, assertion) \
 ((likely(assertion)) ? 0 : gfs2_assert_warn_i((sdp), #assertion, \
-                                       __FUNCTION__, __FILE__, __LINE__))
+                                       __func__, __FILE__, __LINE__))
 
 
 int gfs2_consist_i(struct gfs2_sbd *sdp, int cluster_wide,
                   const char *function, char *file, unsigned int line);
 
 #define gfs2_consist(sdp) \
-gfs2_consist_i((sdp), 0, __FUNCTION__, __FILE__, __LINE__)
+gfs2_consist_i((sdp), 0, __func__, __FILE__, __LINE__)
 
 
 int gfs2_consist_inode_i(struct gfs2_inode *ip, int cluster_wide,
                         const char *function, char *file, unsigned int line);
 
 #define gfs2_consist_inode(ip) \
-gfs2_consist_inode_i((ip), 0, __FUNCTION__, __FILE__, __LINE__)
+gfs2_consist_inode_i((ip), 0, __func__, __FILE__, __LINE__)
 
 
 int gfs2_consist_rgrpd_i(struct gfs2_rgrpd *rgd, int cluster_wide,
                         const char *function, char *file, unsigned int line);
 
 #define gfs2_consist_rgrpd(rgd) \
-gfs2_consist_rgrpd_i((rgd), 0, __FUNCTION__, __FILE__, __LINE__)
+gfs2_consist_rgrpd_i((rgd), 0, __func__, __FILE__, __LINE__)
 
 
 int gfs2_meta_check_ii(struct gfs2_sbd *sdp, struct buffer_head *bh,
@@ -91,7 +91,7 @@ static inline int gfs2_meta_check_i(struct gfs2_sbd *sdp,
 }
 
 #define gfs2_meta_check(sdp, bh) \
-gfs2_meta_check_i((sdp), (bh), __FUNCTION__, __FILE__, __LINE__)
+gfs2_meta_check_i((sdp), (bh), __func__, __FILE__, __LINE__)
 
 
 int gfs2_metatype_check_ii(struct gfs2_sbd *sdp, struct buffer_head *bh,
@@ -118,7 +118,7 @@ static inline int gfs2_metatype_check_i(struct gfs2_sbd *sdp,
 }
 
 #define gfs2_metatype_check(sdp, bh, type) \
-gfs2_metatype_check_i((sdp), (bh), (type), __FUNCTION__, __FILE__, __LINE__)
+gfs2_metatype_check_i((sdp), (bh), (type), __func__, __FILE__, __LINE__)
 
 static inline void gfs2_metatype_set(struct buffer_head *bh, u16 type,
                                     u16 format)
@@ -134,14 +134,14 @@ int gfs2_io_error_i(struct gfs2_sbd *sdp, const char *function,
                    char *file, unsigned int line);
 
 #define gfs2_io_error(sdp) \
-gfs2_io_error_i((sdp), __FUNCTION__, __FILE__, __LINE__);
+gfs2_io_error_i((sdp), __func__, __FILE__, __LINE__);
 
 
 int gfs2_io_error_bh_i(struct gfs2_sbd *sdp, struct buffer_head *bh,
                       const char *function, char *file, unsigned int line);
 
 #define gfs2_io_error_bh(sdp, bh) \
-gfs2_io_error_bh_i((sdp), (bh), __FUNCTION__, __FILE__, __LINE__);
+gfs2_io_error_bh_i((sdp), (bh), __func__, __FILE__, __LINE__);
 
 
 extern struct kmem_cache *gfs2_glock_cachep;
index 9645275023e68c5b93f582a10d31d541a4a79884..a113ecc3bafeeb5f74172d8d5eb98e09f6eb6979 100644 (file)
        do {                                                            \
                printk(JFFS2_ERR_MSG_PREFIX                             \
                        " (%d) %s: " fmt, task_pid_nr(current),         \
-                       __FUNCTION__ , ##__VA_ARGS__);                  \
+                       __func__ , ##__VA_ARGS__);                      \
        } while(0)
 
 #define JFFS2_WARNING(fmt, ...)                                                \
        do {                                                            \
                printk(JFFS2_WARN_MSG_PREFIX                            \
                        " (%d) %s: " fmt, task_pid_nr(current),         \
-                       __FUNCTION__ , ##__VA_ARGS__);                  \
+                       __func__ , ##__VA_ARGS__);                      \
        } while(0)
 
 #define JFFS2_NOTICE(fmt, ...)                                         \
        do {                                                            \
                printk(JFFS2_NOTICE_MSG_PREFIX                          \
                        " (%d) %s: " fmt, task_pid_nr(current),         \
-                       __FUNCTION__ , ##__VA_ARGS__);                  \
+                       __func__ , ##__VA_ARGS__);                      \
        } while(0)
 
 #define JFFS2_DEBUG(fmt, ...)                                          \
        do {                                                            \
                printk(JFFS2_DBG_MSG_PREFIX                             \
                        " (%d) %s: " fmt, task_pid_nr(current),         \
-                       __FUNCTION__ , ##__VA_ARGS__);                  \
+                       __func__ , ##__VA_ARGS__);                      \
        } while(0)
 
 /*
index e48665984cb3393d1f859e27db42ba29a6937345..574cb7532d6c13e8b0fa6b3e1ccc1638ebfc4201 100644 (file)
@@ -82,7 +82,7 @@ static int is_xattr_datum_unchecked(struct jffs2_sb_info *c, struct jffs2_xattr_
 static void unload_xattr_datum(struct jffs2_sb_info *c, struct jffs2_xattr_datum *xd)
 {
        /* must be called under down_write(xattr_sem) */
-       D1(dbg_xattr("%s: xid=%u, version=%u\n", __FUNCTION__, xd->xid, xd->version));
+       D1(dbg_xattr("%s: xid=%u, version=%u\n", __func__, xd->xid, xd->version));
        if (xd->xname) {
                c->xdatum_mem_usage -= (xd->name_len + 1 + xd->value_len);
                kfree(xd->xname);
@@ -1252,7 +1252,7 @@ int jffs2_garbage_collect_xattr_ref(struct jffs2_sb_info *c, struct jffs2_xattr_
        rc = jffs2_reserve_space_gc(c, totlen, &length, JFFS2_SUMMARY_XREF_SIZE);
        if (rc) {
                JFFS2_WARNING("%s: jffs2_reserve_space_gc() = %d, request = %u\n",
-                             __FUNCTION__, rc, totlen);
+                             __func__, rc, totlen);
                rc = rc ? rc : -EBADFD;
                goto out;
        }
index 40b16f23e49af4eb99c8060d5e52aad370e0613c..5df517b81f3f2a7911e1518c33021e9eb557c85e 100644 (file)
@@ -573,7 +573,7 @@ again:
                /* Ensure the resulting lock will get added to granted list */
                fl->fl_flags |= FL_SLEEP;
                if (do_vfs_lock(fl) < 0)
-                       printk(KERN_WARNING "%s: VFS is out of sync with lock manager!\n", __FUNCTION__);
+                       printk(KERN_WARNING "%s: VFS is out of sync with lock manager!\n", __func__);
                up_read(&host->h_rwsem);
                fl->fl_flags = fl_flags;
                status = 0;
index 4d81553d29485e69dd19e746a1edadf4618c8d91..81aca859bfde909f2574c2c7f9e9e02608a1a165 100644 (file)
@@ -752,7 +752,7 @@ nlmsvc_grant_blocked(struct nlm_block *block)
                return;
        default:
                printk(KERN_WARNING "lockd: unexpected error %d in %s!\n",
-                               -error, __FUNCTION__);
+                               -error, __func__);
                nlmsvc_insert_block(block, 10 * HZ);
                nlmsvc_release_block(block);
                return;
index 2d4358c59f681fc939206fb064f66284ea0d599e..05ff4f1d7026f4fbed45d09208c4b8cda3a0a72e 100644 (file)
@@ -609,7 +609,7 @@ error_inode:
        if (corrupt < 0) {
                fat_fs_panic(new_dir->i_sb,
                             "%s: Filesystem corrupted (i_pos %lld)",
-                            __FUNCTION__, sinfo.i_pos);
+                            __func__, sinfo.i_pos);
        }
        goto out;
 }
index 061e5edb4d271395a37709b4503a007a70c7bdd7..4fc302c2a0e0f886e4026288bcdc50888ddf3551 100644 (file)
@@ -2329,10 +2329,10 @@ void __init mnt_init(void)
        err = sysfs_init();
        if (err)
                printk(KERN_WARNING "%s: sysfs_init error: %d\n",
-                       __FUNCTION__, err);
+                       __func__, err);
        fs_kobj = kobject_create_and_add("fs", NULL);
        if (!fs_kobj)
-               printk(KERN_WARNING "%s: kobj create error\n", __FUNCTION__);
+               printk(KERN_WARNING "%s: kobj create error\n", __func__);
        init_rootfs();
        init_mount_tree();
 }
index 562abf3380d032e96342589fa13232233698c130..0b3ffa9840c20e0530ee4f9de9aa423cb813fc52 100644 (file)
@@ -104,7 +104,7 @@ xdr_writemem(__be32 *p, const void *ptr, int nbytes)
 } while (0)
 #define RESERVE_SPACE(nbytes)   do {                            \
        p = xdr_reserve_space(xdr, nbytes);                     \
-       if (!p) dprintk("NFSD: RESERVE_SPACE(%d) failed in function %s\n", (int) (nbytes), __FUNCTION__); \
+       if (!p) dprintk("NFSD: RESERVE_SPACE(%d) failed in function %s\n", (int) (nbytes), __func__); \
        BUG_ON(!p);                                             \
 } while (0)
 
@@ -134,7 +134,7 @@ xdr_error:                                      \
        p = xdr_inline_decode(xdr, nbytes); \
        if (!p) { \
                dprintk("NFSD: %s: reply buffer overflowed in line %d.\n", \
-                       __FUNCTION__, __LINE__); \
+                       __func__, __LINE__); \
                return -EIO; \
        } \
 } while (0)
index 8ac37c33d1278ef7d602e5dd3aa57de98e1d2236..5e6724c1afd1d0276d7e839c9bfcbd2832fbd600 100644 (file)
@@ -45,7 +45,7 @@ static void ntfs_debug(const char *f, ...);
 extern void __ntfs_debug (const char *file, int line, const char *function,
        const char *format, ...) __attribute__ ((format (printf, 4, 5)));
 #define ntfs_debug(f, a...)                                            \
-       __ntfs_debug(__FILE__, __LINE__, __FUNCTION__, f, ##a)
+       __ntfs_debug(__FILE__, __LINE__, __func__, f, ##a)
 
 extern void ntfs_debug_dump_runlist(const runlist_element *rl);
 
@@ -58,10 +58,10 @@ extern void ntfs_debug_dump_runlist(const runlist_element *rl);
 
 extern void __ntfs_warning(const char *function, const struct super_block *sb,
                const char *fmt, ...) __attribute__ ((format (printf, 3, 4)));
-#define ntfs_warning(sb, f, a...)      __ntfs_warning(__FUNCTION__, sb, f, ##a)
+#define ntfs_warning(sb, f, a...)      __ntfs_warning(__func__, sb, f, ##a)
 
 extern void __ntfs_error(const char *function, const struct super_block *sb,
                const char *fmt, ...) __attribute__ ((format (printf, 3, 4)));
-#define ntfs_error(sb, f, a...)                __ntfs_error(__FUNCTION__, sb, f, ##a)
+#define ntfs_error(sb, f, a...)                __ntfs_error(__func__, sb, f, ##a)
 
 #endif /* _LINUX_NTFS_DEBUG_H */
index e7dd1d4e34734c6c139dbd1f8486becaa418a166..0fdda2e8a4cc916648b035a1f962eaf8744797fa 100644 (file)
 #ifndef CONFIG_LDM_DEBUG
 #define ldm_debug(...) do {} while (0)
 #else
-#define ldm_debug(f, a...) _ldm_printk (KERN_DEBUG, __FUNCTION__, f, ##a)
+#define ldm_debug(f, a...) _ldm_printk (KERN_DEBUG, __func__, f, ##a)
 #endif
 
-#define ldm_crit(f, a...)  _ldm_printk (KERN_CRIT,  __FUNCTION__, f, ##a)
-#define ldm_error(f, a...) _ldm_printk (KERN_ERR,   __FUNCTION__, f, ##a)
-#define ldm_info(f, a...)  _ldm_printk (KERN_INFO,  __FUNCTION__, f, ##a)
+#define ldm_crit(f, a...)  _ldm_printk (KERN_CRIT,  __func__, f, ##a)
+#define ldm_error(f, a...) _ldm_printk (KERN_ERR,   __func__, f, ##a)
+#define ldm_info(f, a...)  _ldm_printk (KERN_INFO,  __func__, f, ##a)
 
 __attribute__ ((format (printf, 3, 4)))
 static void _ldm_printk (const char *level, const char *function,
index 734972b92694f03493e9440eb86f8557ba8621f3..fc4b1a5dd75531739bdd0d856e2f85782c3fe356 100644 (file)
  * these are normally enabled.
  */
 #ifdef SMBFS_PARANOIA
-# define PARANOIA(f, a...) printk(KERN_NOTICE "%s: " f, __FUNCTION__ , ## a)
+# define PARANOIA(f, a...) printk(KERN_NOTICE "%s: " f, __func__ , ## a)
 #else
 # define PARANOIA(f, a...) do { ; } while(0)
 #endif
 
 /* lots of debug messages */
 #ifdef SMBFS_DEBUG_VERBOSE
-# define VERBOSE(f, a...) printk(KERN_DEBUG "%s: " f, __FUNCTION__ , ## a)
+# define VERBOSE(f, a...) printk(KERN_DEBUG "%s: " f, __func__ , ## a)
 #else
 # define VERBOSE(f, a...) do { ; } while(0)
 #endif
@@ -28,7 +28,7 @@
  * too common name.
  */
 #ifdef SMBFS_DEBUG
-#define DEBUG1(f, a...) printk(KERN_DEBUG "%s: " f, __FUNCTION__ , ## a)
+#define DEBUG1(f, a...) printk(KERN_DEBUG "%s: " f, __func__ , ## a)
 #else
 #define DEBUG1(f, a...) do { ; } while(0)
 #endif
index dbdfabbfd609661b6c585b8bc9962dae2d057634..e7735f643cd1b03eab8560479d6f691e387ce218 100644 (file)
@@ -135,7 +135,7 @@ sysfs_read_file(struct file *file, char __user *buf, size_t count, loff_t *ppos)
                        goto out;
        }
        pr_debug("%s: count = %zd, ppos = %lld, buf = %s\n",
-                __FUNCTION__, count, *ppos, buffer->page);
+                __func__, count, *ppos, buffer->page);
        retval = simple_read_from_buffer(buf, count, ppos, buffer->page,
                                         buffer->count);
 out:
index 74168266cd59a1abca9e8039131c0ce46b240980..14f0023984d74d6a51dedc0791fdfab53f2d5cc4 100644 (file)
@@ -61,7 +61,7 @@ static int sysfs_fill_super(struct super_block *sb, void *data, int silent)
        /* instantiate and link root dentry */
        root = d_alloc_root(inode);
        if (!root) {
-               pr_debug("%s: could not get root dentry!\n",__FUNCTION__);
+               pr_debug("%s: could not get root dentry!\n",__func__);
                iput(inode);
                return -ENOMEM;
        }
index b564fc140fe4e90efc24b7b7f231a5676aa979b6..9fb18a340fc1efa95fb0acd15d50c89c90652875 100644 (file)
@@ -240,7 +240,7 @@ static int udf_sb_alloc_partition_maps(struct super_block *sb, u32 count)
        sbi->s_partmaps = kcalloc(count, sizeof(struct udf_part_map),
                                  GFP_KERNEL);
        if (!sbi->s_partmaps) {
-               udf_error(sb, __FUNCTION__,
+               udf_error(sb, __func__,
                          "Unable to allocate space for %d partition maps",
                          count);
                sbi->s_partitions = 0;
@@ -1086,7 +1086,7 @@ static struct udf_bitmap *udf_sb_alloc_bitmap(struct super_block *sb, u32 index)
                bitmap = vmalloc(size); /* TODO: get rid of vmalloc */
 
        if (bitmap == NULL) {
-               udf_error(sb, __FUNCTION__,
+               udf_error(sb, __func__,
                          "Unable to allocate space for bitmap "
                          "and %d buffer_head pointers", nr_groups);
                return NULL;
index 5b66162d0747e647eb53f2349c19a86ed7f59cb8..a3522727ea5b090ea4ee02d925e7327cde21fe7b 100644 (file)
@@ -986,7 +986,7 @@ error_inode:
        if (corrupt < 0) {
                fat_fs_panic(new_dir->i_sb,
                             "%s: Filesystem corrupted (i_pos %lld)",
-                            __FUNCTION__, sinfo.i_pos);
+                            __func__, sinfo.i_pos);
        }
        goto out;
 }