All of lore.kernel.org
 help / color / mirror / Atom feed
From: ehrhardt@linux.vnet.ibm.com
To: fio@vger.kernel.org
Cc: Christian Ehrhardt <ehrhardt@linux.vnet.ibm.com>
Subject: [patch 2/2] [PATCH] fio: fix s390 nop
Date: Tue, 08 Apr 2014 17:52:01 +0200	[thread overview]
Message-ID: <20140408155246.244233350@linux.vnet.ibm.com> (raw)
In-Reply-To: 20140408155159.696154675@linux.vnet.ibm.com

[-- Attachment #1: fix-s390-nop.diff --]
[-- Type: text/plain, Size: 900 bytes --]

From: Christian Ehrhardt <ehrhardt@linux.vnet.ibm.com>

When trying to run rate limited fio runs we encountered that the current
definition of a nop uses a privileged instruction which is not even a nop,
but a yield call to the hipervisor.
That leads to a SIGILL as it is privileged.

To solve that issue replace it with a nop, the assembler will take care
of it (likely to become a BCR 0,0)

Signed-off-by: Christian Ehrhardt <ehrhardt@linux.vnet.ibm.com>
---

[diffstat]
 arch/arch-s390.h |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

[diff]
--- a/arch/arch-s390.h
+++ b/arch/arch-s390.h
@@ -18,7 +18,7 @@
 #define __NR_sys_vmsplice	309
 #endif
 
-#define nop		asm volatile ("diag 0,0,68" : : : "memory")
+#define nop		asm volatile("nop" : : : "memory")
 #define read_barrier()	asm volatile("bcr 15,0" : : : "memory")
 #define write_barrier()	asm volatile("bcr 15,0" : : : "memory")
 


  parent reply	other threads:[~2014-04-08 15:52 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-08 15:51 [patch 0/2] timing and nop fixes for the s390 architecture ehrhardt
2014-04-08 15:52 ` [patch 1/2] [PATCH] fio: fix s390 time accounting ehrhardt
2014-04-08 15:52 ` ehrhardt [this message]
2014-04-08 16:11 ` [patch 0/2] timing and nop fixes for the s390 architecture Jens Axboe

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=20140408155246.244233350@linux.vnet.ibm.com \
    --to=ehrhardt@linux.vnet.ibm.com \
    --cc=fio@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.