diff options
author | Kenji Aoyama <aoyama@cvs.openbsd.org> | 2023-01-27 13:58:18 +0000 |
---|---|---|
committer | Kenji Aoyama <aoyama@cvs.openbsd.org> | 2023-01-27 13:58:18 +0000 |
commit | d7fb9c3de0e20f84672004e9136645df5979e4a3 (patch) | |
tree | 712c6e543270a0889631c7590734ec4287b46a81 /sys | |
parent | b332958ecf7a8440499af1f660edf5ebc4ee11fe (diff) |
Delete get_plane_numbers() function.
Different from original LUNA(68k), the number of planes is directly
stored as an integer value on LUNA-88K.
Tested on LUNA-88K2 by me.
Diffstat (limited to 'sys')
-rw-r--r-- | sys/arch/luna88k/stand/boot/init_main.c | 18 |
1 files changed, 2 insertions, 16 deletions
diff --git a/sys/arch/luna88k/stand/boot/init_main.c b/sys/arch/luna88k/stand/boot/init_main.c index 91ecc09f25a..fbe39498161 100644 --- a/sys/arch/luna88k/stand/boot/init_main.c +++ b/sys/arch/luna88k/stand/boot/init_main.c @@ -1,4 +1,4 @@ -/* $OpenBSD: init_main.c,v 1.10 2023/01/10 17:10:57 miod Exp $ */ +/* $OpenBSD: init_main.c,v 1.11 2023/01/27 13:58:17 aoyama Exp $ */ /* $NetBSD: init_main.c,v 1.6 2013/03/05 15:34:53 tsutsui Exp $ */ /* @@ -109,7 +109,6 @@ const char version[] = "0.8"; static void get_fuse_rom_data(void); static void get_nvram_data(void); -static int get_plane_numbers(void); static const char *nvram_by_symbol(char *); int cpuspeed; /* for DELAY() macro */ @@ -167,7 +166,7 @@ main(void) cpuspeed = MHZ_33; } - nplane = get_plane_numbers(); + nplane = *((int *)0x1114); /* 0, 1, 4, or 8 */ cninit(); #ifdef SUPPORT_ETHERNET @@ -187,19 +186,6 @@ main(void) /* NOTREACHED */ } -int -get_plane_numbers(void) -{ - int r = *((int *)0x1114); - int n = 0; - - for (; r ; r >>= 1) - if (r & 0x1) - n++; - - return(n); -} - /* Get data from FUSE ROM */ void |