From patchwork Fri May 24 08:53:35 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Vetter X-Patchwork-Id: 10959433 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 0CCB515A6 for ; Fri, 24 May 2019 08:55:14 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id ED8B52884B for ; Fri, 24 May 2019 08:55:13 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E1B5B28852; Fri, 24 May 2019 08:55:13 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 94F492884B for ; Fri, 24 May 2019 08:55:13 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 690546E0C2; Fri, 24 May 2019 08:54:28 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-ed1-x542.google.com (mail-ed1-x542.google.com [IPv6:2a00:1450:4864:20::542]) by gabe.freedesktop.org (Postfix) with ESMTPS id 56DA46E0BE for ; Fri, 24 May 2019 08:54:23 +0000 (UTC) Received: by mail-ed1-x542.google.com with SMTP id f37so13271667edb.13 for ; Fri, 24 May 2019 01:54:23 -0700 (PDT) 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:mime-version:content-transfer-encoding; bh=qFqlt6mo9F4Pd9G7O8MT8qo6u/5jZNMJ/2yl3qsAQiY=; b=bMlcNpws1PkkPgCQg8gNXTH805Inw+EQurKf+pCQHjpTDJ/vXV6yMJnw2klssw0TP8 d8mRJkMLYVx3N2J9d2VDqQyBDi6r3Ko32EQMalnUsXWBh+mQCDa69zkElCfuNTQXH/Yn avo/U1s354bIA73tr5b4Uzk2rq9hrZfawehrOFOseU90C0f48g1gHxbWOVySz97tY/Ro fAL913TE9bfoucVmIVgQoLdPSn1C7KTSVagkn7mN3CcqxGUMo+6dJEH6Wy5VPOegxMH3 vGVIaVEaINjL+EboRjKE/n4JJWXo+/sFTaqddbaidtAAkDBqkCQQNT8N3R0gZtOULwDk vfQg== X-Gm-Message-State: APjAAAXsxUYGkVyhMovw2yZ9FzSMjgNLJQfhy+OqPJvuFZgOR52sLMpg zs+FklMAVJm0196PQmWd51U0YQ== X-Google-Smtp-Source: APXvYqxfH4m8cM3kQ2a9m5Bu7sZt3awOs0EZLiDpP3Rw5DPOFSPeezL+a7RRX9L5t0jF0ChIS5R+Zw== X-Received: by 2002:a50:908a:: with SMTP id c10mr102215126eda.226.1558688060655; Fri, 24 May 2019 01:54:20 -0700 (PDT) Received: from phenom.ffwll.local ([2a02:168:569e:0:3106:d637:d723:e855]) by smtp.gmail.com with ESMTPSA id 96sm567082edq.68.2019.05.24.01.54.19 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 24 May 2019 01:54:19 -0700 (PDT) From: Daniel Vetter To: LKML Subject: [PATCH 14/33] staging/olpc: lock_fb_info can't fail Date: Fri, 24 May 2019 10:53:35 +0200 Message-Id: <20190524085354.27411-15-daniel.vetter@ffwll.ch> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190524085354.27411-1-daniel.vetter@ffwll.ch> References: <20190524085354.27411-1-daniel.vetter@ffwll.ch> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ffwll.ch; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=qFqlt6mo9F4Pd9G7O8MT8qo6u/5jZNMJ/2yl3qsAQiY=; b=EgPw0s1XuffFZvuQmIb+u1grhbjqLNzg/527P2g071z9I1Srgh63ZYAtIrTqJ9/3WB 4fGr4+vWcQgnQhJwsaUixthTYD4PW/g7mB8dJEg2qZkoDJYIjq9AS/XYnSozEbuQlWH0 0XPhcaEJ9eNRxGY5BRpufgjXn4h9qrDKGVZ08= X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Daniel Drake , Jens Frederich , Daniel Vetter , DRI Development , Intel Graphics Development Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP Simply because olpc never unregisters the damn thing. It also registers the framebuffer directly by poking around in fbdev core internals, so it's all around rather broken. Signed-off-by: Daniel Vetter Cc: Jens Frederich Cc: Daniel Drake Cc: Jon Nettleton Acked-by: Greg Kroah-Hartman --- drivers/staging/olpc_dcon/olpc_dcon.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/drivers/staging/olpc_dcon/olpc_dcon.c b/drivers/staging/olpc_dcon/olpc_dcon.c index 6b714f740ac3..a254238be181 100644 --- a/drivers/staging/olpc_dcon/olpc_dcon.c +++ b/drivers/staging/olpc_dcon/olpc_dcon.c @@ -250,11 +250,7 @@ static bool dcon_blank_fb(struct dcon_priv *dcon, bool blank) int err; console_lock(); - if (!lock_fb_info(dcon->fbinfo)) { - console_unlock(); - dev_err(&dcon->client->dev, "unable to lock framebuffer\n"); - return false; - } + lock_fb_info(dcon->fbinfo); dcon->ignore_fb_events = true; err = fb_blank(dcon->fbinfo,