From: Ralf Baechle <ralf@linux-mips.org>
To: linux-mips@linux-mips.org
Subject: Warning about add_wired_entry
Date: Mon, 7 Dec 2009 15:02:36 +0000 [thread overview]
Message-ID: <20091207150236.GD19269@linux-mips.org> (raw)
The earlier posting wrt. add_wired_entry reminded my of this long standing
issue.
The kernel does not reserve any address space for use by add_wired_entry().
In other words there is the possibility that vmalloc, ioremap or other
kernel APIs will use the same address space resulting in a crash or worse.
Currently there are three users of add_wired_entry:
- Alchemy
- Cavium
- Jazz
The interface itself also is hostile as it directly exposes the MIPS TLB
registers to the C programmer so should die. And often wiring a TLB entry
is a bad idea. TLB entries are a scarce resource and wasting them unwisely
may impact performance. Especially on the lowest-end CPUs with just
16 TLB entries this can be significant but even on the high-end TLBs with
64 entries it's not always clear if wiring entries is a good idea. And
there are a few core types that don't even have the capability of wiring
entries.
Ralf
next reply other threads:[~2009-12-07 15:02 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-12-07 15:02 Ralf Baechle [this message]
2009-12-07 15:41 ` Warning about add_wired_entry pascal
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20091207150236.GD19269@linux-mips.org \
--to=ralf@linux-mips.org \
--cc=linux-mips@linux-mips.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).