mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-12-02 21:32:58 +00:00
MFC r274820:
Merge from CheriBSD (2e28d2a309
):
Remove initalized, but unused devname variable
Sponsored by: DARPA, AFRL
This commit is contained in:
parent
f30cc098ca
commit
1b9574b685
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/stable/10/; revision=275428
@ -321,7 +321,6 @@ altera_avgen_attach(struct altera_avgen_softc *sc, const char *str_fileio,
|
||||
const char *str_mmapio, const char *str_devname, int devunit)
|
||||
{
|
||||
device_t dev = sc->avg_dev;
|
||||
char devname[SPECNAMELEN + 1];
|
||||
int error;
|
||||
|
||||
error = altera_avgen_process_options(sc, str_fileio, str_mmapio,
|
||||
@ -329,18 +328,6 @@ altera_avgen_attach(struct altera_avgen_softc *sc, const char *str_fileio,
|
||||
if (error)
|
||||
return (error);
|
||||
|
||||
/* Select a device name. */
|
||||
if (str_devname != NULL) {
|
||||
if (devunit != -1)
|
||||
(void)snprintf(devname, sizeof(devname), "%s%d",
|
||||
str_devname, devunit);
|
||||
else
|
||||
(void)snprintf(devname, sizeof(devname), "%s",
|
||||
str_devname);
|
||||
} else
|
||||
snprintf(devname, sizeof(devname), "%s%d", "avgen",
|
||||
sc->avg_unit);
|
||||
|
||||
if (rman_get_size(sc->avg_res) >= PAGE_SIZE || str_mmapio != NULL) {
|
||||
if (rman_get_size(sc->avg_res) % PAGE_SIZE != 0) {
|
||||
device_printf(dev,
|
||||
|
Loading…
Reference in New Issue
Block a user