2003-01-07 Yoshinori K. Okuji <okuji@enbug.org>

* util/i386/pc/pupa-setup.c (setup): Convert the endianness of
		the length of a blocklist correctly.

			* util/i386/pc/biosdisk.c (pupa_util_biosdisk_open) [__linux__]:
				Use ioctl only if the OS file is a block device.
					(pupa_util_biosdisk_open): Don't use ST.ST_BLOCKS, because it is
						not very useful for normal files.

							* kern/main.c (pupa_set_root_dev): New function.
								(pupa_load_normal_mode): Likewise.
									(pupa_main): Call those above.

										* include/pupa/types.h (pupa_swap_bytes16): Cast the result to
											pupa_uint16_t.

												* include/pupa/kernel.h (pupa_enter_normal_mode): Removed.
This commit is contained in:
okuji 2003-01-07 07:54:07 +00:00
parent a5ffe96617
commit a13f92373c
6 changed files with 95 additions and 17 deletions

View file

@ -55,7 +55,4 @@ pupa_addr_t pupa_get_end_addr (void);
/* Register all the exported symbols. This is automatically generated. */
void pupa_register_exported_symbols (void);
/* Enter normal mode. */
void pupa_enter_normal_mode (void);
#endif /* ! PUPA_KERNEL_HEADER */

View file

@ -85,7 +85,7 @@ typedef pupa_int32_t pupa_ssize_t;
#define pupa_swap_bytes16(x) \
({ \
pupa_uint16_t _x = (x); \
(_x << 8) | (_x >> 8); \
(pupa_uint16_t) ((_x << 8) | (_x >> 8)); \
})
#define pupa_swap_bytes32(x) \