__FUNCTION__ -> __func__

This commit is contained in:
tsutsui 2007-06-29 16:41:31 +00:00
parent 096f2d0ee4
commit 446e7b7d8c
1 changed files with 9 additions and 11 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: disksubr.c,v 1.4 2007/02/22 05:31:53 thorpej Exp $ */
/* $NetBSD: disksubr.c,v 1.5 2007/06/29 16:41:31 tsutsui Exp $ */
/*-
* Copyright (c) 2004 The NetBSD Foundation, Inc.
@ -37,7 +37,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: disksubr.c,v 1.4 2007/02/22 05:31:53 thorpej Exp $");
__KERNEL_RCSID(0, "$NetBSD: disksubr.c,v 1.5 2007/06/29 16:41:31 tsutsui Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -71,7 +71,7 @@ readdisklabel(dev_t dev, void (*strategy)(struct buf *), struct disklabel *d,
/* Read VTOC */
if (!pdinfo_sector(rwops, pdinfo) || !pdinfo_sanity(pdinfo)) {
DPRINTF("%s: PDINFO not found.\n", __FUNCTION__);
DPRINTF("%s: PDINFO not found.\n", __func__);
} else if (vtoc_sector(rwops, vtoc, pdinfo->logical_sector) &&
vtoc_sanity(vtoc)) {
vtoc_available = true;
@ -82,11 +82,10 @@ readdisklabel(dev_t dev, void (*strategy)(struct buf *), struct disklabel *d,
disklabel_available = true;
memcpy(d, buf, sizeof(struct disklabel));
} else {
DPRINTF("%s: no BSD disklabel.\n", __FUNCTION__);
DPRINTF("%s: no BSD disklabel.\n", __func__);
}
} else {
DPRINTF("%s: PDINFO found, but VTOC not found.\n",
__FUNCTION__);
DPRINTF("%s: PDINFO found, but VTOC not found.\n", __func__);
}
sector_fini(rwops);
@ -94,10 +93,10 @@ readdisklabel(dev_t dev, void (*strategy)(struct buf *), struct disklabel *d,
if (!disklabel_available) {
if (vtoc_available) {
DPRINTF("%s: creating disklabel from VTOC.\n",
__FUNCTION__);
__func__);
} else {
DPRINTF("%s: no VTOC. creating default disklabel.\n",
__FUNCTION__);
__func__);
vtoc_set_default(ux, d);
}
disklabel_set_default(d);
@ -135,8 +134,7 @@ writedisklabel(dev_t dev, void (*strategy)(struct buf *), struct disklabel *d,
/* 1. Update VTOC */
disklabel_to_vtoc(ux, d);
DPRINTF("%s: logical_sector=%d\n", __FUNCTION__,
ux->pdinfo.logical_sector);
DPRINTF("%s: logical_sector=%d\n", __func__, ux->pdinfo.logical_sector);
if ((rwops = sector_init(dev, strategy)) == 0)
return ENOMEM;
@ -152,7 +150,7 @@ writedisklabel(dev_t dev, void (*strategy)(struct buf *), struct disklabel *d,
memset(buf, 0, sizeof buf);
memcpy(buf, d, sizeof *d);
if (!sector_write(rwops, buf, LABELSECTOR)) {
DPRINTF("%s: failed to write disklabel.\n", __FUNCTION__);
DPRINTF("%s: failed to write disklabel.\n", __func__);
err = EIO;
}
sector_fini(rwops);