Message ID | 20211026083138.1818705-4-jens.wiklander@linaro.org |
---|---|
State | Superseded |
Headers | show
Delivered-To: patches@linaro.org Received: by 2002:ac0:c404:0:0:0:0:0 with SMTP id t4csp50582imj; Tue, 26 Oct 2021 01:31:47 -0700 (PDT) X-Received: by 2002:a2e:a444:: with SMTP id v4mr24531405ljn.33.1635237106852; Tue, 26 Oct 2021 01:31:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635237106; cv=none; d=google.com; s=arc-20160816; b=vP0SCTJpvhYNQhpxqY4Ow1/6Dc67u5G7VfSfV3b4h7WPuW5bUHEQN1XNHDEY2p6qgz fFEd3Ff/pOiW2wpQTV+MlQBPGg1tb+nsGBitFTIw5hUREoVeuR+pH11nZKWQpLdfN0RT av9pReZpMJT7o8CsIiljf/Yc0FqNu6AO5rFVWosLdNheirP/0wRzkmqTRNE76Tgkfwbm 5OvFyLsUs39OOjt4EG/UilfsjTv/TJD45OHZJto9nVhHZ3hxBVIhdo5iBXvuJYlXvCaA 9LmPRjJVE9xHLlChIcvX19pJJOT7upczJ6yrfLdBUnMEmSzZ1n/uwf99ioI/aJjq9grd vpsQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature; bh=wDFhL54jBz3G05V/OraPaakr11gEhiPI9haVEV4Ys5E=; b=eFWIVW5qMfQWNmWR9cZqFpRCVdHfTyAiRKTM5zsMD1uXnudUls1idiA9+mf5sKJ/kf 5D8GC8o2e1EwrrCaiNUIOwRjrm3xug1ifsU58UMgwQhKazrw//+KVSW5jjodfstGq4aq jZXgAd8msOHCyuEbmXU1n1zHZ96Pho1GRxBx7Ds+9rXkcuHDuPfqsNOOMJ9GL1+AvZSi mY+LOACcCcBTJAwA9GKO5M8dfcy4y6Rst42wNpW4AFEp07QXWKejXuVMBNGuX8hi5Sk7 bI0AupdBWGXcqLqCb+31kYbzG0YO9jKOrEkoXtfA3IhZMdkCURDigLoaLge+61AbaVGN t0Aw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="ZHi/y1ck"; spf=pass (google.com: domain of jens.wiklander@linaro.org designates 209.85.220.41 as permitted sender) smtp.mailfrom=jens.wiklander@linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: <jens.wiklander@linaro.org> Received: from mail-sor-f41.google.com (mail-sor-f41.google.com. [209.85.220.41]) by mx.google.com with SMTPS id e8sor9718731ljo.59.2021.10.26.01.31.46 for <patches@linaro.org> (Google Transport Security); Tue, 26 Oct 2021 01:31:46 -0700 (PDT) Received-SPF: pass (google.com: domain of jens.wiklander@linaro.org designates 209.85.220.41 as permitted sender) client-ip=209.85.220.41; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="ZHi/y1ck"; spf=pass (google.com: domain of jens.wiklander@linaro.org designates 209.85.220.41 as permitted sender) smtp.mailfrom=jens.wiklander@linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org 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 :mime-version:content-transfer-encoding; bh=wDFhL54jBz3G05V/OraPaakr11gEhiPI9haVEV4Ys5E=; b=ZHi/y1ckyJDjwvb69REwPJQs4kGYBOXGfL3+pN25jVWAnTb2vKBp6jHF3eT3WtRHBM AUKxjjI9Y1MAMOa2cMBBmpQq1yWCcw5kPu6bxnNkHnVTvm6Od5nnp/Qz2Lw1il+AtgOJ UO2WlWEILwrTrxFEUQPtKcp2R3ZyKvGAktqwiJMEx+mlnbeavtRyiq4kUSBBiuVDRg5/ jtoV5pnrzqYaHP/2Ex/cQB9QnIeN3zq2KOpSX4MR80M4kdxOVAWd4Tt5u4jtFajw5QWd v6MCweJFr7CAwUr2g1r4qe/og5hMaHzWypDTsintIjJTYWttSWDIHgqYrSKG841m/fnG zYMQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=wDFhL54jBz3G05V/OraPaakr11gEhiPI9haVEV4Ys5E=; b=zGlwv6VG0ZpLrziD6oslz0492grMIVL6J+3YAp47dapkY43ytSmg2Mbf8zVZKfODxH JdKFwrSjAxd7Xb3yBn/MF7hFRP8jb4lBo/+iOTknVORfkf+xiU/4gzcrNo6mOd4VDqT1 3UbSkAOZlynnBdApMiOKRIew2J2uM13JF2UcRx42Bi2wjNNcE+2Rt7mrpi9dveTEXlJU lP5ydH8loRRvTSSy8LUOdmS1TVJ8376/4/OthLA+1hCz2VBSwOima40brNqyOohBKcUE Gl6jtICUyisxsnm/PZ/i1vkPdHQcSRPd4HYdLtKgxEiia9EdR6wactkm/CM/JkYUr8AE CuIw== X-Gm-Message-State: AOAM530vPF+JdPEmcLaJzx0h0wk/OJEIGpt3Zt/dybDFqdnw7AqJY8ph 5sQ2SURAFGRP6LTXMksjFugB8PSp X-Google-Smtp-Source: ABdhPJzBJhd2BrrH13cjClJSpD9eKt3Bq+FtJpQvAGc+zfqBSWAgY3ScNVoHesZAWSmLf0vhy2Fmnw== X-Received: by 2002:a05:651c:327:: with SMTP id b7mr4963654ljp.85.1635237106519; Tue, 26 Oct 2021 01:31:46 -0700 (PDT) Return-Path: <jens.wiklander@linaro.org> Received: from jade.urgonet (h-94-254-48-165.A175.priv.bahnhof.se. [94.254.48.165]) by smtp.gmail.com with ESMTPSA id e4sm1944598ljn.131.2021.10.26.01.31.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 26 Oct 2021 01:31:46 -0700 (PDT) From: Jens Wiklander <jens.wiklander@linaro.org> To: linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, op-tee@lists.trustedfirmware.org, devicetree@vger.kernel.org, linux-doc@vger.kernel.org Cc: Jerome Forissier <jerome@forissier.org>, Etienne Carriere <etienne.carriere@linaro.org>, Sumit Garg <sumit.garg@linaro.org>, Vincent Guittot <vincent.guittot@linaro.org>, Rob Herring <robh+dt@kernel.org>, Jonathan Corbet <corbet@lwn.net>, Ard Biesheuvel <ardb@kernel.org>, Marc Zyngier <maz@kernel.org>, jens.vankeirsbilck@kuleuven.be, Jens Wiklander <jens.wiklander@linaro.org> Subject: [PATCH v7 3/6] tee: fix put order in teedev_close_context() Date: Tue, 26 Oct 2021 10:31:35 +0200 Message-Id: <20211026083138.1818705-4-jens.wiklander@linaro.org> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211026083138.1818705-1-jens.wiklander@linaro.org> References: <20211026083138.1818705-1-jens.wiklander@linaro.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit |
Series |
Asynchronous notifications from secure world
|
expand
|
diff --git a/drivers/tee/tee_core.c b/drivers/tee/tee_core.c index 2b37bc408fc3..85102d12d716 100644 --- a/drivers/tee/tee_core.c +++ b/drivers/tee/tee_core.c @@ -98,8 +98,10 @@ void teedev_ctx_put(struct tee_context *ctx) static void teedev_close_context(struct tee_context *ctx) { - tee_device_put(ctx->teedev); + struct tee_device *teedev = ctx->teedev; + teedev_ctx_put(ctx); + tee_device_put(teedev); } static int tee_open(struct inode *inode, struct file *filp)