From patchwork Thu Apr 25 18:35:41 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ezequiel Garcia X-Patchwork-Id: 10917613 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 35A271390 for ; Thu, 25 Apr 2019 18:36:54 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 294BD28CF5 for ; Thu, 25 Apr 2019 18:36:54 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1D66828CF8; Thu, 25 Apr 2019 18:36:54 +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=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI,UNPARSEABLE_RELAY autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id C380728CF5 for ; Thu, 25 Apr 2019 18:36:53 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727331AbfDYSgw (ORCPT ); Thu, 25 Apr 2019 14:36:52 -0400 Received: from bhuna.collabora.co.uk ([46.235.227.227]:35394 "EHLO bhuna.collabora.co.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725941AbfDYSgw (ORCPT ); Thu, 25 Apr 2019 14:36:52 -0400 Received: from [127.0.0.1] (localhost [127.0.0.1]) (Authenticated sender: ezequiel) with ESMTPSA id 4CC912841F1 From: Ezequiel Garcia To: Philipp Zabel , linux-media@vger.kernel.org, Hans Verkuil Cc: kernel@collabora.com, Ezequiel Garcia Subject: [PATCH 0/5] Assorted CODA fixes Date: Thu, 25 Apr 2019 15:35:41 -0300 Message-Id: <20190425183546.16244-1-ezequiel@collabora.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP While working on a SoC with CODA980 (currently not supported by the driver), I came across some low-hanging fruit that looked worth addressing. Patch 1 is just a cosmetic change to print a different "more standard" device registered message, if such thing exists. Patches 2 to 4 address unneeded usage of threaded interrupt and deferred worker. Careful code inspection shows the interrupt can be serviced on a normal handler. In this regard, the driver is still waiting for job completion in the .device_run hook, which the framework already does. Therefore, there are two waits: one in the driver, one in the mem2mem core. Please note that I'm not addressing this for now. Finally, patch 5 clears a hardware register called INT_REASON. Without this clearing the firmware has been found to get stuck on our CODA980. I believe this fix might be useful to carry upstream, because it's so small and we have some indications that it's actually the right thing to do. Ezequiel Garcia (5): media: coda: Print a nicer device registered message media: coda: Remove unbalanced and unneeded mutex unlock media: coda: Replace the threaded interrupt with a hard interrupt media: coda: Remove pic_run_work worker media: coda: Clear the interrupt reason drivers/media/platform/coda/coda-bit.c | 2 +- drivers/media/platform/coda/coda-common.c | 26 ++++++++++------------- drivers/media/platform/coda/coda.h | 1 - 3 files changed, 12 insertions(+), 17 deletions(-)