Use OF_prop_free instead of direct call to free(9)
This commit is contained in:
parent
836229c3cf
commit
bb307f247a
@ -126,7 +126,7 @@ at91_pinctrl_setup_dinfo(device_t dev, phandle_t node)
|
||||
resource_list_add(&ndi->rl, SYS_RES_MEMORY, k,
|
||||
phys, phys + size - 1, size);
|
||||
}
|
||||
free(reg, M_OFWPROP);
|
||||
OF_prop_free(reg);
|
||||
|
||||
nintr = OF_getencprop_alloc(node, "interrupts", sizeof(*intr),
|
||||
(void **)&intr);
|
||||
@ -154,7 +154,7 @@ at91_pinctrl_setup_dinfo(device_t dev, phandle_t node)
|
||||
resource_list_add(&ndi->rl, SYS_RES_IRQ, k, intr[i],
|
||||
intr[i], 1);
|
||||
}
|
||||
free(intr, M_OFWPROP);
|
||||
OF_prop_free(intr);
|
||||
}
|
||||
|
||||
return (ndi);
|
||||
@ -429,7 +429,7 @@ pinctrl_configure_pins(device_t bus, phandle_t cfgxref)
|
||||
break;
|
||||
}
|
||||
}
|
||||
free(cfgdata, M_OFWPROP);
|
||||
OF_prop_free(cfgdata);
|
||||
return (0);
|
||||
}
|
||||
|
||||
|
@ -176,7 +176,7 @@ iomux_configure_pins(device_t dev, phandle_t cfgxref)
|
||||
cfg->padconf_reg, cfg->padconf_val);
|
||||
}
|
||||
}
|
||||
free(cfgtuples, M_OFWPROP);
|
||||
OF_prop_free(cfgtuples);
|
||||
return (0);
|
||||
}
|
||||
|
||||
|
@ -234,7 +234,7 @@ fdt_localbus_reg_decode(phandle_t node, struct localbus_softc *sc,
|
||||
}
|
||||
rv = 0;
|
||||
out:
|
||||
free(reg, M_OFWPROP);
|
||||
OF_prop_free(reg);
|
||||
return (rv);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user