linux-mips
[Top] [All Lists]

Re: [PATCH] jump label: Add MIPS support.

To: David Daney <ddaney@caviumnetworks.com>
Subject: Re: [PATCH] jump label: Add MIPS support.
From: Rabin Vincent <rabin@rab.in>
Date: Sun, 3 Oct 2010 23:45:37 +0530
Cc: linux-mips@linux-mips.org, ralf@linux-mips.org, linux-kernel@vger.kernel.org, rostedt@goodmis.org, jbaron@redhat.com
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:sender:received :in-reply-to:references:date:x-google-sender-auth:message-id:subject :from:to:cc:content-type:content-transfer-encoding; bh=7kaYeLnWNk4mV3KhMb5mIc5FX7CIKUJk6PTjIjK9pQA=; b=ir5Cu51+CYPQODTV68NShqT9YKr2DK43St1ol79nsmKESvQuyPnbVH9NN2c2y1hG9/ puIvpTaq7aAsSwiOuCis2mLrkM0vJF9YuZuTES/DyfXoHTSYpnYlJCTsT0qdtuw4HMdm ef/2BqRjpx7qXkhbbPWVcxre9oOHclhoGXuZ4=
Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; b=WXHm9LqLqhQSWLUxNj8fo+mJjjaJ71Q6nUnXgsIXZes1Fwyo+JRlXosyERsZ/ykJAH ITDtLjM0AWvp8HY1VQvjfVA1yvhEmqRSlkH2jTriy+bi3C8pQKBZIL0+exopzRNGoaT+ airncLhbiivCHigcC4aNlZrV+1Dg0uOU2D0mA=
In-reply-to: <1285697432-29244-1-git-send-email-ddaney@caviumnetworks.com>
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <1285697432-29244-1-git-send-email-ddaney@caviumnetworks.com>
Sender: linux-mips-bounce@linux-mips.org
On Tue, Sep 28, 2010 at 11:40 PM, David Daney <ddaney@caviumnetworks.com> wrote:
> +void arch_jump_label_text_poke_early(jump_label_t addr)
> +{
> +       union mips_instruction *insn_p =
> +               (union mips_instruction *)(unsigned long)addr;
> +
> +       insn_p->word = 0; /* nop */
> +       flush_icache_range((unsigned long)insn_p,
> +                          (unsigned long)insn_p + sizeof(*insn_p));
> +}

Can't this function be a no-op on MIPS?  This seems to be
used on x86 to patch in the optimal nop instruction, but
on MIPS the optimal/only nop instruction should already
be in place at build time.  Same thing for the SPARC
implementation.

Rabin

<Prev in Thread] Current Thread [Next in Thread>