Message ID | 1435830563-3072-10-git-send-email-zhaoshenglong@huawei.com |
---|---|
State | New |
Headers | show
Return-Path: <patchwork-forward+bncBDPILVOKSELBBLET2SWAKGQEAQDGDAA@linaro.org> X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wg0-f69.google.com (mail-wg0-f69.google.com [74.125.82.69]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 8912D218E1 for <linaro@patches.linaro.org>; Thu, 2 Jul 2015 09:51:41 +0000 (UTC) Received: by wgjx7 with SMTP id x7sf19690864wgj.3 for <linaro@patches.linaro.org>; Thu, 02 Jul 2015 02:51:40 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:date:message-id:in-reply-to :references:mime-version:content-type:cc:subject:precedence:list-id :list-unsubscribe:list-archive:list-post:list-help:list-subscribe :errors-to:sender:x-original-sender :x-original-authentication-results:mailing-list; bh=XUfvxXx16AxNmNCcPKjkG+5QZFGYoyGt4YG0KpHtLpI=; b=mMb/Bf2GCyqaBTwLyo7L6fYQurYlVGpg5rEesn/FeA7KhJ2+lbzPqfbzqxUngx9nTG IWkbcL3P7QfgHKsWpxeDP2l5aBnAcL4KJ3hvaUG2v0rNGUhUNEBeRi3MNK4fehOEzN8D G3IWPTGGB5jb0xrsAe0Ff+yw1/tM6WEVjV3t0frEuyXGFsHQ5cWeIY9GwrqwYQUU6T7x XOhEuILoLV0YMk8bU/dxk+fZUQIWJPAHIXTeJmLXTzXnHHuNOjRg/QKYez1XCSC6iEH+ 3sgEJKi2kfnXLdzFh1gpGPKlS6nCryziJqtgsz60fh1bYrEZb6Rl8VSY744GPkJqG4f8 8mwQ== X-Gm-Message-State: ALoCoQndOgsJAOT4j4UW6Hqr35jDzoO7Gt02lkOD8Gp5G5HjRKPESubEVlIqEbgmf3qdSBdStzsy X-Received: by 10.112.181.37 with SMTP id dt5mr5997006lbc.10.1435830700784; Thu, 02 Jul 2015 02:51:40 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.27.10 with SMTP id p10ls319105lag.29.gmail; Thu, 02 Jul 2015 02:51:40 -0700 (PDT) X-Received: by 10.112.73.33 with SMTP id i1mr18355119lbv.31.1435830700285; Thu, 02 Jul 2015 02:51:40 -0700 (PDT) Received: from mail-lb0-f169.google.com (mail-lb0-f169.google.com. [209.85.217.169]) by mx.google.com with ESMTPS id bd7si4028382lab.39.2015.07.02.02.51.40 for <patchwork-forward@linaro.org> (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 02 Jul 2015 02:51:40 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.169 as permitted sender) client-ip=209.85.217.169; Received: by lbnk3 with SMTP id k3so28638364lbn.1 for <patchwork-forward@linaro.org>; Thu, 02 Jul 2015 02:51:40 -0700 (PDT) X-Received: by 10.112.93.37 with SMTP id cr5mr29806281lbb.106.1435830700169; Thu, 02 Jul 2015 02:51:40 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.108.230 with SMTP id hn6csp352698lbb; Thu, 2 Jul 2015 02:51:39 -0700 (PDT) X-Received: by 10.68.229.40 with SMTP id sn8mr63626065pbc.59.1435830698068; Thu, 02 Jul 2015 02:51:38 -0700 (PDT) Received: from lists.gnu.org (lists.gnu.org. [208.118.235.17]) by mx.google.com with ESMTPS id 6si8203120pdd.149.2015.07.02.02.51.37 for <patch@linaro.org> (version=TLSv1 cipher=RC4-SHA bits=128/128); Thu, 02 Jul 2015 02:51:38 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; Received: from localhost ([::1]:35611 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from <qemu-devel-bounces+patch=linaro.org@nongnu.org>) id 1ZAb9c-0001j2-NN for patch@linaro.org; Thu, 02 Jul 2015 05:51:36 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:36184) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from <zhaoshenglong@huawei.com>) id 1ZAb8L-0000Ma-9h for qemu-devel@nongnu.org; Thu, 02 Jul 2015 05:50:18 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from <zhaoshenglong@huawei.com>) id 1ZAb8K-0008Ru-EV for qemu-devel@nongnu.org; Thu, 02 Jul 2015 05:50:17 -0400 Received: from szxga02-in.huawei.com ([119.145.14.65]:58099) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from <zhaoshenglong@huawei.com>) id 1ZAb8E-0008Nt-7A; Thu, 02 Jul 2015 05:50:10 -0400 Received: from 172.24.2.119 (EHLO szxeml428-hub.china.huawei.com) ([172.24.2.119]) by szxrg02-dlp.huawei.com (MOS 4.3.7-GA FastPath queued) with ESMTP id CNZ28157; Thu, 02 Jul 2015 17:50:03 +0800 (CST) Received: from HGHY1Z002260041.china.huawei.com (10.177.16.142) by szxeml428-hub.china.huawei.com (10.82.67.183) with Microsoft SMTP Server id 14.3.158.1; Thu, 2 Jul 2015 17:49:53 +0800 From: Shannon Zhao <zhaoshenglong@huawei.com> To: <qemu-devel@nongnu.org> Date: Thu, 2 Jul 2015 17:49:22 +0800 Message-ID: <1435830563-3072-10-git-send-email-zhaoshenglong@huawei.com> X-Mailer: git-send-email 1.9.0.msysgit.0 In-Reply-To: <1435830563-3072-1-git-send-email-zhaoshenglong@huawei.com> References: <1435830563-3072-1-git-send-email-zhaoshenglong@huawei.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.177.16.142] X-CFilter-Loop: Reflected X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] X-Received-From: 119.145.14.65 Cc: qemu-trivial@nongnu.org, mjt@tls.msk.ru, shannon.zhao@linaro.org Subject: [Qemu-devel] [PATCH 09/10] hw/mips/mips_int.c: use qemu_allocate_irq to fix memory leak X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: <patchwork-forward.linaro.org> List-Unsubscribe: <mailto:googlegroups-manage+836684582541+unsubscribe@googlegroups.com>, <http://groups.google.com/a/linaro.org/group/patchwork-forward/subscribe> List-Archive: <http://groups.google.com/a/linaro.org/group/patchwork-forward/> List-Post: <http://groups.google.com/a/linaro.org/group/patchwork-forward/post>, <mailto:patchwork-forward@linaro.org> List-Help: <http://support.google.com/a/linaro.org/bin/topic.py?topic=25838>, <mailto:patchwork-forward+help@linaro.org> List-Subscribe: <https://lists.nongnu.org/mailman/listinfo/qemu-devel>, <mailto:qemu-devel-request@nongnu.org?subject=subscribe> Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: patch@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.169 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 |
diff --git a/hw/mips/mips_int.c b/hw/mips/mips_int.c index d740046..e463a46 100644 --- a/hw/mips/mips_int.c +++ b/hw/mips/mips_int.c @@ -59,12 +59,11 @@ static void cpu_mips_irq_request(void *opaque, int irq, int level) void cpu_mips_irq_init_cpu(CPUMIPSState *env) { - qemu_irq *qi; int i; - qi = qemu_allocate_irqs(cpu_mips_irq_request, mips_env_get_cpu(env), 8); for (i = 0; i < 8; i++) { - env->irq[i] = qi[i]; + env->irq[i] = qemu_allocate_irq(cpu_mips_irq_request, + mips_env_get_cpu(env), i); } }