From patchwork Wed Jun 17 21:02:22 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robert Foley X-Patchwork-Id: 190947 Delivered-To: patch@linaro.org Received: by 2002:a92:cf06:0:0:0:0:0 with SMTP id c6csp816332ilo; Wed, 17 Jun 2020 14:31:41 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw9z6RFP8H7sjFEOkK7NUhcHuOj74tI4n0PiqGXwx9GULYFva+Su0l7f1NGduM6ZlkbPZh8 X-Received: by 2002:a25:d652:: with SMTP id n79mr1634159ybg.406.1592429500829; Wed, 17 Jun 2020 14:31:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1592429500; cv=none; d=google.com; s=arc-20160816; b=JeGHIGBva3JdbJPijd1Id5g6Pn08lTsAZvycmC1YhRL0qpulSABPhBCSWl/5Yt0Dtt Ukhjwi4BZxdEZmYstBIjflr3YaOsYKc2GEOKs80M+Ec3zLOsBGjJmPqzHrgtYKL+JmIw TNTelUD5ZNYFphnOdIbukbl/8sDXe+D0BNJLL7jxITFpDkJyJsP62qUdbui+a0g8JZry csn9kE0K8qtFvfZF6jQbBHHnZrfaN8Fqh7anZiSlYu3hrvIqZ6nK49mguGUvsuYJZoP5 e+nSO5oRrGltnBZR1o8Zq2p0SIwCNjQPVI8AMQx0Drm53EO9Q0QOly+pv3FlvG7coihQ OYuw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:references:in-reply-to :message-id:date:subject:to:from:dkim-signature; bh=Gn2vKDOISxQzKy44RYpzzeOAg/5NGEBTOA6wtcYZvN4=; b=SIthW+hxTQcR4Mw5YMjW5dXBNR8X0Lh7x7Khv4zGMhTHMOIQCh1Xn1/LQ3q385eFzf WsaHoYF93iRt47IcSx7iHDwiy+7k3u1uR7uwKHyqOR/8Kju2jvV3xJNGlKXTjk+34FdV d21RZ8Kfxc0Ev0PyivFO4qmrvozEjsWaK4CoKQVe7ZfebqSnQNy04sxlWf1MwlaNpdX2 LRyvYhfTpjMHtawlyNUEP7hC4aRwfheKGJz4P1o6noHRmvEHzgQ6j1940G5omgi7dxQx t55PzrQDSx58cNWz5+JrkrLWiPVHfPAiP+46IdDJxViPSzV9WD2ISSvAP/nIt+L8Ar18 15iA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=Thm2aHey; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id b7si668030ybo.295.2020.06.17.14.31.40 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 17 Jun 2020 14:31:40 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=Thm2aHey; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:51846 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jlfem-0006o3-5y for patch@linaro.org; Wed, 17 Jun 2020 17:31:40 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:38160) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jlfEs-0004d9-Ll for qemu-devel@nongnu.org; Wed, 17 Jun 2020 17:04:54 -0400 Received: from mail-qt1-x844.google.com ([2607:f8b0:4864:20::844]:46918) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jlfEm-0000OY-VU for qemu-devel@nongnu.org; Wed, 17 Jun 2020 17:04:54 -0400 Received: by mail-qt1-x844.google.com with SMTP id g18so2725211qtu.13 for ; Wed, 17 Jun 2020 14:04:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=Gn2vKDOISxQzKy44RYpzzeOAg/5NGEBTOA6wtcYZvN4=; b=Thm2aHeyJvMESgiuasvN/HjzFdRSeqqVQq4LmqV7D6GB6694ajgYvGe/9WpkcXcr7F H6koOjMcYHMlU58jiBD/na7kpp3MbsoTyX0KplAxlwrt2ZmSeI/rh5fM8TdZticOuv0p Z1vjrEEY1KGN1jCiWJwqToxP+qrfb2n72GLHYu9mJqEYeG3CUlJzq4Eky3Kx2UvuHPHN aMlcJ1moeBFKEZ07hjG6Nhi29ltknA7u72gd+Wrac+8dyTBBsAfs1wIVelDyGhrH+pG+ PPsjFOGYYUXi0b4Dv6yGb227Q5Ef2PKsuQMeOhRBSfupxxYGQECJ0uMoPk4M83egmmQx rsew== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=Gn2vKDOISxQzKy44RYpzzeOAg/5NGEBTOA6wtcYZvN4=; b=eK+bamCd/z262bhZrdAt9o1bJRpRneSS+H1nOJqtmyNSaC6hbb+uaKBxEAAbDv3Lmb IWFDcC1ucWfvAXg2J0zoFksB/58J7NpNkqVF3m08mplZDVZdoNp9t14uZpOWIfBRJUmf PsEH7PcmefK05FG9QBP6+T69O9kHBBaBYk79fMqs2E3gO9oN2wfI10DkNj7XC5UVPa8Q pcj1rm6Ov43tH0VHH4Wst1pJ5jsWjdp5wz241rXZm1AxZy7+FW/Ew+l90n2nNWhPWx0/ D6Wmwbnr083jaVTWuAURHM+Xczvw5sHyHHJYhS+H7phe1xAUCHn1bI264mHR8ry01QHP n9Gw== X-Gm-Message-State: AOAM531hWh/5SWwtiDRLiLha723myIuM73+b4DGDrBbiWIry9QQY4/jb snnozBt+aYlfCBtWt42P/BkNLu/09ol46w== X-Received: by 2002:ac8:51d5:: with SMTP id d21mr1141796qtn.154.1592427887822; Wed, 17 Jun 2020 14:04:47 -0700 (PDT) Received: from Rfoley-MA01.hsd1.ma.comcast.net ([2601:199:4480:60c0:fc79:714c:9711:2e9c]) by smtp.gmail.com with ESMTPSA id w13sm997245qkb.91.2020.06.17.14.04.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 17 Jun 2020 14:04:47 -0700 (PDT) From: Robert Foley To: qemu-devel@nongnu.org Subject: [PATCH v10 64/73] mips: convert to cpu_has_work_with_iothread_lock Date: Wed, 17 Jun 2020 17:02:22 -0400 Message-Id: <20200617210231.4393-65-robert.foley@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200617210231.4393-1-robert.foley@linaro.org> References: <20200617210231.4393-1-robert.foley@linaro.org> Received-SPF: pass client-ip=2607:f8b0:4864:20::844; envelope-from=robert.foley@linaro.org; helo=mail-qt1-x844.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Aleksandar Rikalo , robert.foley@linaro.org, Aleksandar Markovic , cota@braap.org, peter.puhov@linaro.org, alex.bennee@linaro.org, Aurelien Jarno Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: "Emilio G. Cota" Soon we will call cpu_has_work without the BQL. Cc: Aurelien Jarno Cc: Aleksandar Markovic Reviewed-by: Richard Henderson Signed-off-by: Emilio G. Cota Signed-off-by: Robert Foley --- target/mips/cpu.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) -- 2.17.1 diff --git a/target/mips/cpu.c b/target/mips/cpu.c index 761d8aaa54..ec9dde5100 100644 --- a/target/mips/cpu.c +++ b/target/mips/cpu.c @@ -58,6 +58,8 @@ static bool mips_cpu_has_work(CPUState *cs) bool has_work = false; uint32_t interrupt_request = cpu_interrupt_request(cs); + g_assert(qemu_mutex_iothread_locked()); + /* * Prior to MIPS Release 6 it is implementation dependent if non-enabled * interrupts wake-up the CPU, however most of the implementations only @@ -193,7 +195,7 @@ static void mips_cpu_class_init(ObjectClass *c, void *data) device_class_set_parent_reset(dc, mips_cpu_reset, &mcc->parent_reset); cc->class_by_name = mips_cpu_class_by_name; - cc->has_work = mips_cpu_has_work; + cc->has_work_with_iothread_lock = mips_cpu_has_work; cc->do_interrupt = mips_cpu_do_interrupt; cc->cpu_exec_interrupt = mips_cpu_exec_interrupt; cc->dump_state = mips_cpu_dump_state;