Etienne Lorrain <etienne_lorrain@yahoo.fr> writes:
> The code is compiling if the structure is small enough to fit in
> a 32 bits register, not if it has to be in memory - I should have
> said it. With the compiler I have nearby, this code is only
> compiling if the line "// unsigned c, d, e, f;" is commented out:
>
> ---------------------------
> typedef struct {
> unsigned char a,b;
> // unsigned c, d, e, f;
> } ebiosinfo_t;
>
> unsigned char
> _EBIOSDISK_getparam (unsigned char disk, ebiosinfo_t *ebiosinfo,
> unsigned char *status)
> {
> unsigned char carry;
>
> asm (
> " int $0x13 # _EBIOSDISK_getparam \n"
> " mov %%ah,%1 \n"
> " setc %0 \n"
> : "=qm" (carry), "=qm" (*status)
> : "a"((unsigned short)0x4800), "d" (disk), "S" (*ebiosinfo)
> );
You've hit PR inline-asm/8788. As I mentioned there, IMHO we should
error out on this, but nobody else has commented on it yet...
--
Falk