Date: Thu, 30 Jan 2020 23:23:02 +0000 From: Rick Macklem <rmacklem@uoguelph.ca> To: "freebsd-current@FreeBSD.org" <freebsd-current@FreeBSD.org> Subject: easy way to work around a lack of a direct map on i386 Message-ID: <YTBPR01MB3374AA25792499A796DB7CAADD040@YTBPR01MB3374.CANPRD01.PROD.OUTLOOK.COM>
next in thread | raw e-mail | index | archive | help
Hi,=0A= =0A= The current code for KERN_TLS uses PHYS_TO_DMAP()=0A= to access unmapped external pages on m_ext.ext_pgs=0A= mbufs.=0A= I also need to do this to implement RPC-over-TLS.=0A= =0A= The problem is that some arches, like i386, don't=0A= support PHYS_TO_DMAP().=0A= =0A= Since it appears that there will be at most 4 pages on=0A= one of these mbufs, my thinking was...=0A= - Acquire four pages of kva from the kernel_map during=0A= booting.=0A= - Then just use pmap_qenter() to fill in the physical page=0A= mappings for long enough to copy the data.=0A= =0A= Does this sound reasonable?=0A= Is there a better way?=0A= =0A= Thanks for your comments, rick=0A=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?YTBPR01MB3374AA25792499A796DB7CAADD040>