From mboxrd@z Thu Jan 1 00:00:00 1970 From: Harry Kalogirou Subject: Re: Swap support Date: 22 Apr 2002 19:29:43 +0300 Sender: linux-8086-owner@vger.kernel.org Message-ID: <1019492981.479.128.camel@cool> References: <1019465227.5698.58.camel@cool> <3CC4132C.3807ECC@dit.upm.es> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="=-czhClZeVQu7mcCcFmNoD" Return-path: In-Reply-To: <3CC4132C.3807ECC@dit.upm.es> List-Id: To: Javier Sedano Cc: Linux-8086 --=-czhClZeVQu7mcCcFmNoD Content-Type: text/plain; charset=ISO-8859-7 Content-Transfer-Encoding: quoted-printable =D4=E7=ED =C4=E5=F5, 22-04-2002 =F3=F4=E9=F2 16:42, =EF/=E7 Javier Sedano = =DD=E3=F1=E1=F8=E5: > Harry Kalogirou wrote: > >=20 > '> Yesterday I commited to the CVS some experimental swap support code, > > based on Alan's work on the subject. Ofcourse this code is not included > > in the default configuration and is not for _actual_ use, since as I > > said is experimental. Apart from that if you set the swap partition in > > malloc.c you and enable swapping you can enjoy an 8086 system use > > _virtual_ memory! > >=20 >=20 > Great! >=20 > I've been looking for it in the code, and found nothing about it's > configuration (setting the partition and the size, activating it...)... > can someone (Harry, Alan) give us a few words about how to do so? I will focus on making it easily configurable at run time later along with documenting it a bit. Basicaly the code now is a 4 hour brain storm. To configure it you basicaly change this part of the code : holep =3D &swap_holes[0]; holep->flags =3D HOLE_FREE; holep->page_base =3D 0; holep->extent =3D 128; holep->refcount =3D 0; holep->next =3D NULL; swap_dev =3D 0x0100; The extent is the size in kilobytes and the swap_dev is the block device to swap to. In the example 0x0100 is /dev/ram0 > And by the way... can you write a technical description about how is it > done? The main problem with swap in minix was (is) that processes It's on my TODO list... > waiting for IO (waiting for a message from FS) can not be swapped in, > because they would meet a deadlock when trying to swap out (for FS is > needed again to do the swapping out, but it is frozen sending the > message to the process, because FS is not reentrant/concurrent in > minix)... and obviously processes waiting for IO are those best suited > to be swapped in. >=20 As you might already noticed we don't use the FS layer, we only support swapping to a device at the momment. Once the think works we can add swapping to file easily. For the minix matter now - our FS is reentrant so we will have no problem... Harry --=-czhClZeVQu7mcCcFmNoD Content-Type: application/pgp-signature; name=signature.asc -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.6 (GNU/Linux) Comment: For info see http://www.gnupg.org iD8DBQA8xDp1XrjIZPA34x8RAqeCAJwJRrtcsT8ZYP0nSM60M+xRGQA4TwCg2wfY Y+JOXhI1RqPmydoFiGUhqvg= =TH+z -----END PGP SIGNATURE----- --=-czhClZeVQu7mcCcFmNoD--