mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Michael S. Tsirkin" <mst@mellanox.co.il>
To: linux-kernel@vger.kernel.org
Subject: kmap_atomic slot collision
Date: Thu, 15 Dec 2005 19:33:53 +0200	[thread overview]
Message-ID: <20051215173353.GA29402@mellanox.co.il> (raw)

Hi!
I'm trying to use kmap_atomic from both interrupt and task context.
My idea was to do local_irq_save and then use KM_IRQ0/KM_IRQ1:
since I'm disabling interrupts I assumed that this should be safe.
The relevant code is here:
https://openib.org/svn/gen2/trunk/src/linux-kernel/infiniband/ulp/sdp/sdp_iocb.c

However, under stress I see errors from arch/i386/mm/highmem.c:42
        if (!pte_none(*(kmap_pte-idx)))
                BUG();

Apparently, my routine, running from a task context, races with
some other kernel code, and so I'm trying to use a slot that was not
yet unmapped.

Anyone has an idea on what I could be doing wrong?

Thanks,
-- 
MST

             reply	other threads:[~2005-12-15 17:30 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-12-15 17:33 Michael S. Tsirkin [this message]
2005-12-17 20:37 ` Andrew Morton
2005-12-17 21:05   ` Michael S. Tsirkin

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=20051215173353.GA29402@mellanox.co.il \
    --to=mst@mellanox.co.il \
    --cc=linux-kernel@vger.kernel.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

all inboxes | Powered by JetHome®