summaryrefslogtreecommitdiff
path: root/usr/src
diff options
context:
space:
mode:
authorToomas Soome <tsoome@me.com>2018-11-27 15:15:26 +0200
committerToomas Soome <tsoome@me.com>2019-12-27 20:05:07 +0200
commitf772f0f818f73daf7235ea98001eb45736057eb4 (patch)
treede39ee9c205baf9e5a4d05f869d7dee499bbfe29 /usr/src
parentd9a262d9c411812b053dc33b7b8ab0f230c6fb00 (diff)
downloadillumos-joyent-f772f0f818f73daf7235ea98001eb45736057eb4.tar.gz
12121 prtconf: cast between incompatible function types
Reviewed by: Andy Fiddaman <andy@omniosce.org> Reviewed by: C Fraire <cfraire@me.com> Approved by: Robert Mustacchi <rm@fingolfin.org>
Diffstat (limited to 'usr/src')
-rw-r--r--usr/src/cmd/prtconf/pdevinfo.c22
1 files changed, 14 insertions, 8 deletions
diff --git a/usr/src/cmd/prtconf/pdevinfo.c b/usr/src/cmd/prtconf/pdevinfo.c
index a187d25eca..c8b26b61b2 100644
--- a/usr/src/cmd/prtconf/pdevinfo.c
+++ b/usr/src/cmd/prtconf/pdevinfo.c
@@ -102,7 +102,7 @@ typedef struct dumpops {
typedef struct di_args {
di_prom_handle_t prom_hdl;
di_devlink_handle_t devlink_hdl;
- pcidb_hdl_t *pcidb_hdl;
+ pcidb_hdl_t *pcidb_hdl;
} di_arg_t;
static const dumpops_t sysprop_dumpops = {
@@ -162,7 +162,8 @@ static int unprintable(char *, int);
static int promopen(int);
static void promclose();
static di_node_t find_target_node(di_node_t);
-static void node_display_set(di_node_t);
+static void node_display_private_set(di_node_t);
+static int node_display_set(di_node_t, void *);
static int dump_pciid(char *, int, di_node_t, pcidb_hdl_t *);
void
@@ -266,7 +267,7 @@ prtconf_devinfo(void)
}
/* mark the target node so we display it */
- node_display_set(target_node);
+ node_display_private_set(target_node);
if (opts.o_ancestors) {
/*
@@ -275,7 +276,7 @@ prtconf_devinfo(void)
*/
node = target_node;
while (node = di_parent_node(node))
- node_display_set(node);
+ node_display_private_set(node);
} else {
/*
* when we display device tree nodes the indentation
@@ -298,9 +299,7 @@ prtconf_devinfo(void)
* them as well
*/
(void) di_walk_node(target_node, DI_WALK_CLDFIRST,
- (void *)1,
- (int (*)(di_node_t, void *))
- node_display_set);
+ (void *)1, node_display_set);
}
}
@@ -381,13 +380,20 @@ node_display(di_node_t node)
}
static void
-node_display_set(di_node_t node)
+node_display_private_set(di_node_t node)
{
long data = (long)di_node_private_get(node);
data |= NODE_DISPLAY;
di_node_private_set(node, (void *)data);
}
+static int
+node_display_set(di_node_t node, void *arg __unused)
+{
+ node_display_private_set(node);
+ return (0);
+}
+
#define LNODE_DISPLAYED (1<<0)
static long