[SeaBIOS] Little help with call32
kevin at koconnor.net
Tue Apr 24 01:33:13 CEST 2012
On Mon, Apr 23, 2012 at 03:51:10PM +0900, Daniel Castro wrote:
> Hello All,
> I have a small problem with call32, after I make the call and the
> 32bit code is executed the parameter I am sending is incorrect, so
> evidently I am doing something incorrect.
> Here is my 16bit code:
> dprintf(1,"Operation 16bit drive at %p\n",op->drive_g);
> extern void _cfunc32flat_xen_blk_op_read(struct disk_op_s *);
> return call32(_cfunc32flat_xen_blk_op_read,op,DISK_RET_EPARAM);
The 'op' structure is on the stack and the pointer is therefore
relative to the stack segment. Use MAKE_FLATPTR to construct a 32bit
pointer - see pci_writel() for an example.
More information about the SeaBIOS