From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.8 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id D5255C2D0C0 for ; Fri, 6 Dec 2019 02:54:12 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id B490A2173E for ; Fri, 6 Dec 2019 02:54:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726605AbfLFCyK (ORCPT ); Thu, 5 Dec 2019 21:54:10 -0500 Received: from szxga05-in.huawei.com ([45.249.212.191]:6758 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726207AbfLFCyJ (ORCPT ); Thu, 5 Dec 2019 21:54:09 -0500 Received: from DGGEMS407-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id AC3B0FAFD8AEFA6BE712; Fri, 6 Dec 2019 10:54:07 +0800 (CST) Received: from huawei.com (10.175.105.18) by DGGEMS407-HUB.china.huawei.com (10.3.19.207) with Microsoft SMTP Server id 14.3.439.0; Fri, 6 Dec 2019 10:53:59 +0800 From: linmiaohe To: , CC: , , Subject: [PATCH 0/2] use jump label to handle resource release in irq_bypass_register_* Date: Fri, 6 Dec 2019 10:53:51 +0800 Message-ID: <1575600833-12839-1-git-send-email-linmiaohe@huawei.com> X-Mailer: git-send-email 1.8.3.1 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.175.105.18] X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Miaohe Lin Use out_err jump label to help handle resource release. It's a good practice to release resource in one place and help eliminate some duplicated code. Miaohe Lin (2): KVM: lib: use jump label to handle resource release in irq_bypass_register_consumer() KVM: lib: use jump label to handle resource release in irq_bypass_register_producer() virt/lib/irqbypass.c | 38 ++++++++++++++++++++------------------ 1 file changed, 20 insertions(+), 18 deletions(-) -- 2.19.1