From patchwork Fri Aug 26 20:55:16 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 600314 Delivered-To: patch@linaro.org Received: by 2002:a05:7000:4388:0:0:0:0 with SMTP id w8csp652108mae; Fri, 26 Aug 2022 13:58:27 -0700 (PDT) X-Google-Smtp-Source: AA6agR4Cs7IN65y+jknt/0w3Rc2oHExltX4qme0L3vpdQiscx6kJMgaNrjqsGTjSeIh4HnGE2JQI X-Received: by 2002:ad4:5c6c:0:b0:496:c323:6f87 with SMTP id i12-20020ad45c6c000000b00496c3236f87mr1244334qvh.62.1661547507328; Fri, 26 Aug 2022 13:58:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1661547507; cv=none; d=google.com; s=arc-20160816; b=r0wn4QBCHQxILMHGUuuASKWOmSPfMkkRmrcIzVGmcHhc4JfqofRyjWvLbP38OH4RJl bX6FV4okTZyRHfEcMOXY3Krii3gTPwPF9zC5Ov5gn0lN5aGqJPf3EUPaDuJd+yif7JEJ 2aEZj+5sur0xjnaBlKe3gxhfujWXftsu9CSGAnCj5HtU/n5PELlFHXif5NXJa8kwDFsg c9v6PxNaXBRaQCI/XTrcx8IWbR3pTq4Tc2z7LoFw6omsz7oiJVpjOYIXnf3oCNAflvnX hP8kT8LpzfgIRSOwn0fMSbpvh9J9ApyDrJ9ZvotypLgfs0sns1Z6vMKAT9IrKRjZSMQb Ghng== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=5pSXFwSlSVJciy/fhHEgZkCC53rjmr2bP7A8Givhm80=; b=AKRm6ejcICeTXHYrBS1URo4jaVAxbOBmHjKuqIOKK1zv241g8FEO0Qu9nysnO5eoPw n418meg36MfyAq4CABBDJUpkh7nxniNP5R1cj4DR7A6YUM23YjU1ytYSJLPAS41uBw9S 8ZiJyrVN9/qjstMn89COC5bUv0+Wb5x9Oh1N6fEs63sBJNqkeH9ukflsYKn4mEKEYk0J cusbt87rt9vsZ04nT8+nrtgsfJP9Jq6FkONpp9qsaJYyLb8034uQS/YzWwSSWM46emOw Kxvj/EDTHHscvf/6HJV6mrsUW4j7ZfJWNTT58NHdfQoEHvv+3F2TIH0gNYLqpR4/kEiA B13w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=abcU9OBQ; 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=pass (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 c29-20020ac8009d000000b003447fb24bf7si387201qtg.574.2022.08.26.13.58.27 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 26 Aug 2022 13:58:27 -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=pass header.i=@linaro.org header.s=google header.b=abcU9OBQ; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:52164 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oRgPK-0005d3-VV for patch@linaro.org; Fri, 26 Aug 2022 16:58:26 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:51964) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oRgMO-0002ge-Th for qemu-devel@nongnu.org; Fri, 26 Aug 2022 16:55:24 -0400 Received: from mail-pg1-x535.google.com ([2607:f8b0:4864:20::535]:46592) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oRgMN-00033I-5M for qemu-devel@nongnu.org; Fri, 26 Aug 2022 16:55:24 -0400 Received: by mail-pg1-x535.google.com with SMTP id 69so752103pgb.13 for ; Fri, 26 Aug 2022 13:55:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc; bh=5pSXFwSlSVJciy/fhHEgZkCC53rjmr2bP7A8Givhm80=; b=abcU9OBQipr+3mrTRVAf9oJWEfDHhM3FtmsZRN75XUgrn3Kifdo8YhZrPKN9X1tJMu 6XGPA1nQ8lZpsK+aH0GpDslyVAAGu05YzLTuNDX9Y4zTSV4+/WjA0mAvXMpD3OKduSMj WFGzhLUbKLJXFWLpT+uj5Iu4ud9hPMXwh1vimC9H0pnVO0EVMurTr4HAuMK/YfJzFf+L Tl1Wort8lfpf8pis+Vjp+y5Qa34PrLMmWlvEMSYCHxjjumd0kkS8HgwucEBJZ1Cc4h4M s4SLZLFLD7tmCN/OpZvc3BIj70KiBVYm4lPBpXCLQMK/W9z5roz59TiGfw38SEeG8OIA UZyg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc; bh=5pSXFwSlSVJciy/fhHEgZkCC53rjmr2bP7A8Givhm80=; b=I/MXu7MSh7Hf7cSQrhMP9Zc8hcboRuTR4Ly0qRK1UqvyHawBlOgHaPDHw2Tsk7jodH xzqKwDZRnjoCGaX1LaNM1//GSYg3rGVZWcLR1Ktc2xcMe4WR6F+UF2FHR19YVEx04Tg6 P0cX+2Oi3cv8lCqqpD4MBCptzTbvh4TwE1BbXCg0sjG+ZpRKUalzKh6dhUFJhgzYWX9U 4zXkTO4H1QLtTuhRg/XIWEpmSr0FcrJCyrQrWf/GEKLeIvDZBAh842l4mpkfziReS2xT 6iOJtmOJd3VdjoY4dnDqn7WmpK9I1rNZDV2/k42CBEF3LIZi6x/6Y5MNUSScH/RVllvQ lacw== X-Gm-Message-State: ACgBeo0n5qG2J4WbFz6SYL5PosSB/C6iC8utf0mEtfpmgKXClGBKg0Ba EGDXimzMy3w/kbqct0iwBs4aGG5EIcnlBw== X-Received: by 2002:a63:4916:0:b0:427:d463:55e with SMTP id w22-20020a634916000000b00427d463055emr4769271pga.374.1661547321911; Fri, 26 Aug 2022 13:55:21 -0700 (PDT) Received: from stoup.. ([2602:47:d49d:ec01:68d8:30f3:fbd7:6f7f]) by smtp.gmail.com with ESMTPSA id b11-20020a170902650b00b00172a567d910sm2009900plk.289.2022.08.26.13.55.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 26 Aug 2022 13:55:21 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Cc: mrolnik@gmail.com Subject: [PATCH 1/3] target/avr: Call avr_cpu_do_interrupt directly Date: Fri, 26 Aug 2022 13:55:16 -0700 Message-Id: <20220826205518.2339352-2-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220826205518.2339352-1-richard.henderson@linaro.org> References: <20220826205518.2339352-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::535; envelope-from=richard.henderson@linaro.org; helo=mail-pg1-x535.google.com 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, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" There is no need to go through cc->tcg_ops when we know what value that must have. Signed-off-by: Richard Henderson Reviewed-by: Michael Rolnik --- target/avr/helper.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/target/avr/helper.c b/target/avr/helper.c index 82284f8997..9614ccf3e4 100644 --- a/target/avr/helper.c +++ b/target/avr/helper.c @@ -29,14 +29,13 @@ bool avr_cpu_exec_interrupt(CPUState *cs, int interrupt_request) { bool ret = false; - CPUClass *cc = CPU_GET_CLASS(cs); AVRCPU *cpu = AVR_CPU(cs); CPUAVRState *env = &cpu->env; if (interrupt_request & CPU_INTERRUPT_RESET) { if (cpu_interrupts_enabled(env)) { cs->exception_index = EXCP_RESET; - cc->tcg_ops->do_interrupt(cs); + avr_cpu_do_interrupt(cs); cs->interrupt_request &= ~CPU_INTERRUPT_RESET; @@ -47,7 +46,7 @@ bool avr_cpu_exec_interrupt(CPUState *cs, int interrupt_request) if (cpu_interrupts_enabled(env) && env->intsrc != 0) { int index = ctz32(env->intsrc); cs->exception_index = EXCP_INT(index); - cc->tcg_ops->do_interrupt(cs); + avr_cpu_do_interrupt(cs); env->intsrc &= env->intsrc - 1; /* clear the interrupt */ if (!env->intsrc) {