From patchwork Mon Aug 17 08:56:54 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Allen Pais X-Patchwork-Id: 251408 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=-12.5 required=3.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, DKIM_VALID, FREEMAIL_FORGED_FROMDOMAIN, FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH, MAILING_LIST_MULTI, SIGNED_OFF_BY, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT autolearn=unavailable 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 4B65AC433E1 for ; Mon, 17 Aug 2020 09:19:57 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id CE1822072D for ; Mon, 17 Aug 2020 09:19:56 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=alsa-project.org header.i=@alsa-project.org header.b="vuBqyrmS"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="eU8dWmKL" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org CE1822072D Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=alsa-devel-bounces@alsa-project.org Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 5CACF16A5; Mon, 17 Aug 2020 11:19:05 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 5CACF16A5 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1597655995; bh=6WGyDlfgTycmFRSraQJH1sU+kgV0Qw0ErRU9EeEOWiA=; h=From:To:Subject:Date:In-Reply-To:References:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=vuBqyrmS7sVCf0uSHsthgwvrQZySgS1b8Qu2hSwRcRhdZHGWgt51pge2FVay0SfLw mz1+dlSVyppZmZAyf7pmx+/LZMkfNMm61DQYL8qkZe4EB6bdMD+RJUY5fucwq9icgF NSGE1ipbV/LcCQw9RwfFIeZri8SNDkvFeOuYZ3Ic= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 74EAFF802A9; Mon, 17 Aug 2020 11:17:25 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id B1E4AF80216; Mon, 17 Aug 2020 10:57:33 +0200 (CEST) Received: from mail-pj1-x1042.google.com (mail-pj1-x1042.google.com [IPv6:2607:f8b0:4864:20::1042]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id BDC43F80218 for ; Mon, 17 Aug 2020 10:57:23 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz BDC43F80218 Authentication-Results: alsa1.perex.cz; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="eU8dWmKL" Received: by mail-pj1-x1042.google.com with SMTP id 2so7481748pjx.5 for ; Mon, 17 Aug 2020 01:57:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=t7X4N8pkN3GNmV8aMvjwf42XjKAkvV3xHvRmpPGyZyk=; b=eU8dWmKLLv5YTw4tvFvIiBL3Y1IkcJaBGGLUE54vTrcpDfTbismq7GDbmVP1OSDwSu TaGr1/B/34snw/Aqar9BeYatdu4L0OFKOM+gpH5kJ7Yq1EJ9pKbAQ0RV0RcwFfJldm+V g1PkmbwNpM0cfFbKTQLWgqStuCuhmGLakGOMCuSQURnwSI+d6iQFwg0NIhaOCqxtc43A jaZrSY4rFCFm6a1mUQpcNzrtnwO/ZhFTwEG9P9iMcrHKSfjgrG1g183hajzTP4gOHtjc XJraSp0qqdj5OPlXXp/hZre3PcGFgLS0V/5pIUsQ0BC7wfLM7uQqZoRi59mBhkpcs+b0 5hYA== 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; bh=t7X4N8pkN3GNmV8aMvjwf42XjKAkvV3xHvRmpPGyZyk=; b=EFlwFjix4jLoz/kZzfXUkk0FK/HWCIcbUFvQIP8U596rvNkD4pxL7vhZb73epSUl8/ snHGG15FmoTMfq685V3qzVfawjf1K3dQOqnU2XGJhZ/IsSQROGhJBACnATI7CEb5NS/G Z/Xt2aYPERfftJ0/jALkIWEppxGPZmNJVFklo/CypLnHOZnXnmQJYLpSeQg5MxmdiKm9 xDMirs2YZeAhQ3SvFs4xN81ckeBw9fiBafpOcJ+FYvjyG9S9zvL96Y8zCYrm4EcjUC3Y x74sCfAPkfeGoXr2MAqlvYRbOLwynNMXuX21YYgDBUyJ4WC7oZu6dmyijAWjfQfwJP+x b9lQ== X-Gm-Message-State: AOAM530popB5APb+gTCtLly5AvOsy7fTOOm3KtCjPCoep/uTFM6SLiUB ijNcx1Mq8lq0aDfe1cfALhQ= X-Google-Smtp-Source: ABdhPJwP/IQJZ8mysCiHhZ16IDovHskbje8iA1sUnZbb8zig7yuonzpg7I5LA8g+e5ygnIfnJT9yUg== X-Received: by 2002:a17:90a:6d26:: with SMTP id z35mr11434456pjj.164.1597654642315; Mon, 17 Aug 2020 01:57:22 -0700 (PDT) Received: from localhost.localdomain ([49.207.202.98]) by smtp.gmail.com with ESMTPSA id j5sm19057245pfg.80.2020.08.17.01.57.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 17 Aug 2020 01:57:21 -0700 (PDT) From: Allen Pais To: perex@perex.cz, tiwai@suse.com, clemens@ladisch.de, o-takashi@sakamocchi.jp, timur@kernel.org, nicoleotsuka@gmail.com, Xiubo.Lee@gmail.com Subject: [PATCH 01/10] sound: core: convert tasklets to use new tasklet_setup() API Date: Mon, 17 Aug 2020 14:26:54 +0530 Message-Id: <20200817085703.25732-2-allen.cryptic@gmail.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200817085703.25732-1-allen.cryptic@gmail.com> References: <20200817085703.25732-1-allen.cryptic@gmail.com> X-Mailman-Approved-At: Mon, 17 Aug 2020 11:17:21 +0200 Cc: alsa-devel@alsa-project.org, keescook@chromium.org, Allen Pais , linux-kernel@vger.kernel.org, Romain Perier , linuxppc-dev@lists.ozlabs.org X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" From: Allen Pais In preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly. Signed-off-by: Romain Perier Signed-off-by: Allen Pais --- sound/core/timer.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/sound/core/timer.c b/sound/core/timer.c index d9f85f2d66a3..6e27d87b18ed 100644 --- a/sound/core/timer.c +++ b/sound/core/timer.c @@ -816,9 +816,9 @@ static void snd_timer_clear_callbacks(struct snd_timer *timer, * timer tasklet * */ -static void snd_timer_tasklet(unsigned long arg) +static void snd_timer_tasklet(struct tasklet_struct *t) { - struct snd_timer *timer = (struct snd_timer *) arg; + struct snd_timer *timer = from_tasklet(timer, t, task_queue); unsigned long flags; if (timer->card && timer->card->shutdown) { @@ -967,8 +967,7 @@ int snd_timer_new(struct snd_card *card, char *id, struct snd_timer_id *tid, INIT_LIST_HEAD(&timer->ack_list_head); INIT_LIST_HEAD(&timer->sack_list_head); spin_lock_init(&timer->lock); - tasklet_init(&timer->task_queue, snd_timer_tasklet, - (unsigned long)timer); + tasklet_setup(&timer->task_queue, snd_timer_tasklet); timer->max_instances = 1000; /* default limit per timer */ if (card != NULL) { timer->module = card->module; From patchwork Mon Aug 17 08:56:56 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Allen Pais X-Patchwork-Id: 251407 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=-12.5 required=3.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, DKIM_VALID, FREEMAIL_FORGED_FROMDOMAIN, FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH, MAILING_LIST_MULTI, SIGNED_OFF_BY, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT autolearn=unavailable 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 1C891C433E1 for ; Mon, 17 Aug 2020 09:20:49 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 9B8492072D for ; Mon, 17 Aug 2020 09:20:48 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=alsa-project.org header.i=@alsa-project.org header.b="AKL0d7ZE"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="e1cZQ4ub" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 9B8492072D Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=alsa-devel-bounces@alsa-project.org Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 3257D1686; Mon, 17 Aug 2020 11:19:57 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 3257D1686 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1597656047; bh=qRHsHRA7KmECicOC62HgQzrio8TohFZFtpHnGtSa3CE=; h=From:To:Subject:Date:In-Reply-To:References:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=AKL0d7ZEaq2GInrJsjd6Ol9wuAdvkuJuWw6MHGw2NOcIiNoGya2Mu0NX/n1zVOZB1 09cmXxJ7i5M7s+UMUhkFCL4wx+oLpxcOglrsC1yOAIAKzJS8fl/CnOdloMHqg7vYgq wznSBmVEmbTxvIAwGlQh1sueTdTiYpzobGr17R10= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 33ED0F802DB; Mon, 17 Aug 2020 11:17:27 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 3CEE1F80218; Mon, 17 Aug 2020 10:57:43 +0200 (CEST) Received: from mail-pj1-x1044.google.com (mail-pj1-x1044.google.com [IPv6:2607:f8b0:4864:20::1044]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 5CBAAF800EF for ; Mon, 17 Aug 2020 10:57:32 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 5CBAAF800EF Authentication-Results: alsa1.perex.cz; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="e1cZQ4ub" Received: by mail-pj1-x1044.google.com with SMTP id 2so7481924pjx.5 for ; Mon, 17 Aug 2020 01:57:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=GYPUX223cEk7sfseKTxO6Wl2a86PZnTF5NOlEuFwhHI=; b=e1cZQ4ubmOyb/7m500QwlXNssWIHPs/Q6N0IXUiEuPicA0waQPM4rXDUgS7oGR1Qi5 SxkjfKNWKAdDGf6wQs8A5OntcwIGD6wJ5R4FQSDrNtT46ITVL+EnIO0dBjRhPZ31NI+9 xcBpGocniVNBTR3H6kqL1Om6YbYXsebwlyln067CWz+8PoKojJEszmQQbUKxcEP459M2 iBXIB5ZyzBj56xcaODPTZYpADcPDMshAIby+J/sslm3j9yQN7gB6mhZ2XsW+ifVENTAz BLGumgFxMoG1PEiJKxXhZH7jwu32FIbUgdIGMW2GH6TsGWDQB5JTr1WO/Xy+NbOkTUR5 mxUA== 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; bh=GYPUX223cEk7sfseKTxO6Wl2a86PZnTF5NOlEuFwhHI=; b=t5deaNiirdg8nStyhBozO6VXU/6VT84MPZPBduT7oFOMR4iPQxeoUiQ92d/TAOU07v xm7Ozkh/hGjF+v7b0B8dvY+9fiZA10p4nflw7bV6pfPi8yGMd7s3yfG/I7RTi1JevnQK 1rDOzaH8kn0OYygUnleuSIWP3NwvvCH5Gf137w1jnb7HRNAcHfbJB7t/bGK1r6DTGNbD IHLLbeYecfK928whwBLyUlx6/MLHnMMg2IGvHVFIbTkSWbsTyUfke3Yk+xdwX3E+nfha 4P4azVvotULmrBwwbeFk2WaQ4mWwWhNTj9oms9kjcT5UnhqWeJm1sO27dkh7TsboDbQz H+lw== X-Gm-Message-State: AOAM530YaEVhlfd6cvR4EZi+QBRAHiXhziy/I7BlIxE4crgSaU1KTxgj s6KzS9no0OhwhTsJu0BXjK0= X-Google-Smtp-Source: ABdhPJwIJG3YXsNl5fJt9BlQ6Vtf6Rc8gfiB60iBmkaUop2zKiVr9jOHcWia3jkqjMEsJzNj8Bm4+w== X-Received: by 2002:a17:902:9e04:: with SMTP id d4mr10015126plq.296.1597654650775; Mon, 17 Aug 2020 01:57:30 -0700 (PDT) Received: from localhost.localdomain ([49.207.202.98]) by smtp.gmail.com with ESMTPSA id j5sm19057245pfg.80.2020.08.17.01.57.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 17 Aug 2020 01:57:30 -0700 (PDT) From: Allen Pais To: perex@perex.cz, tiwai@suse.com, clemens@ladisch.de, o-takashi@sakamocchi.jp, timur@kernel.org, nicoleotsuka@gmail.com, Xiubo.Lee@gmail.com Subject: [PATCH 03/10] sound: asihpi: convert tasklets to use new tasklet_setup() API Date: Mon, 17 Aug 2020 14:26:56 +0530 Message-Id: <20200817085703.25732-4-allen.cryptic@gmail.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200817085703.25732-1-allen.cryptic@gmail.com> References: <20200817085703.25732-1-allen.cryptic@gmail.com> X-Mailman-Approved-At: Mon, 17 Aug 2020 11:17:21 +0200 Cc: alsa-devel@alsa-project.org, keescook@chromium.org, Allen Pais , linux-kernel@vger.kernel.org, Romain Perier , linuxppc-dev@lists.ozlabs.org X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" From: Allen Pais In preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly. Signed-off-by: Romain Perier Signed-off-by: Allen Pais --- sound/pci/asihpi/asihpi.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/sound/pci/asihpi/asihpi.c b/sound/pci/asihpi/asihpi.c index 023c35a2a951..35e76480306e 100644 --- a/sound/pci/asihpi/asihpi.c +++ b/sound/pci/asihpi/asihpi.c @@ -921,10 +921,10 @@ static void snd_card_asihpi_timer_function(struct timer_list *t) add_timer(&dpcm->timer); } -static void snd_card_asihpi_int_task(unsigned long data) +static void snd_card_asihpi_int_task(struct tasklet_struct *t) { - struct hpi_adapter *a = (struct hpi_adapter *)data; - struct snd_card_asihpi *asihpi; + struct snd_card_asihpi *asihpi = from_tasklet(asihpi, t, t); + struct hpi_adapter *a = asihpi->hpi; WARN_ON(!a || !a->snd_card || !a->snd_card->private_data); asihpi = (struct snd_card_asihpi *)a->snd_card->private_data; @@ -2871,8 +2871,7 @@ static int snd_asihpi_probe(struct pci_dev *pci_dev, if (hpi->interrupt_mode) { asihpi->pcm_start = snd_card_asihpi_pcm_int_start; asihpi->pcm_stop = snd_card_asihpi_pcm_int_stop; - tasklet_init(&asihpi->t, snd_card_asihpi_int_task, - (unsigned long)hpi); + tasklet_setup(&asihpi->t, snd_card_asihpi_int_task); hpi->interrupt_callback = snd_card_asihpi_isr; } else { asihpi->pcm_start = snd_card_asihpi_pcm_timer_start; From patchwork Mon Aug 17 08:56:58 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Allen Pais X-Patchwork-Id: 251406 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=-12.5 required=3.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, DKIM_VALID, FREEMAIL_FORGED_FROMDOMAIN, FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH, MAILING_LIST_MULTI, SIGNED_OFF_BY, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT autolearn=unavailable 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 92A7BC433DF for ; Mon, 17 Aug 2020 09:21:52 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 1DB762072D for ; Mon, 17 Aug 2020 09:21:52 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=alsa-project.org header.i=@alsa-project.org header.b="p1c7ex/c"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="tnVY62Mm" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 1DB762072D Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=alsa-devel-bounces@alsa-project.org Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id A9EB01690; Mon, 17 Aug 2020 11:21:00 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz A9EB01690 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1597656110; bh=La+Nn02jbOZQLGokp98p76QRlTP3kHuIDeBbyvDVpMA=; h=From:To:Subject:Date:In-Reply-To:References:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=p1c7ex/co+2rNU17v1etNI3mRt8r9LdcqY4qYmgJ44sxwvouDyD8Brii7Tptdj9HQ 8wRWclZj4a1NbDL/2lCO2TOei6fgqBCKNKH2sbOORwCf5Y4qXAy0zSYFp86Xfi7kou WWcxHwmxE7QBK5dNFRya0k/ZtYc3WLwSO5dy3njQ= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 443B9F802E9; Mon, 17 Aug 2020 11:17:29 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 1392FF80218; Mon, 17 Aug 2020 10:57:54 +0200 (CEST) Received: from mail-pf1-x442.google.com (mail-pf1-x442.google.com [IPv6:2607:f8b0:4864:20::442]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 664C3F800EF for ; Mon, 17 Aug 2020 10:57:50 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 664C3F800EF Authentication-Results: alsa1.perex.cz; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="tnVY62Mm" Received: by mail-pf1-x442.google.com with SMTP id k18so7894889pfp.7 for ; Mon, 17 Aug 2020 01:57:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=UTSOhqNL5HstpQGSytQ69KLhEIvbIwMRL+50xoY/d1A=; b=tnVY62Mm3nYGST0oeSTRXyKqQJ1c+CoCCnUIazPPvCz2Zyx5i9VDNgtHhs66n21pZw P4WQK0kqDNCBQLWx79G6o67dpbwJPhWt+17dc0HsrLgkWerecLg4kU1AIkrwQFslBYBa lo6RK50/eqXjea5NQ6H/qmPJ5d/LhTJqcY5Wvpy4eRiJzPb6/1l1l/XqqBulYx6AA8Rn b4E5GwDvHlrlvoROyLH70MCyMvgwQ9Ma/CkCSLmwzyT1Lc4KAPigBb5KhVbbv3w22pje /GE4J6Iy8M24q00gdPEdDZwI0qp52uLP2AUdBjM2NmPmIQ7TYyAvbBumeE8H6Z/ojew0 JD3w== 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; bh=UTSOhqNL5HstpQGSytQ69KLhEIvbIwMRL+50xoY/d1A=; b=PYHgXqO53GIqx+MBMf70GewpUVEAdesbsZgMGZRhT8xBnaYvQ94RFE5nG5I1Y3FJH5 b8vrY8K6Zus/1Y3jTzPt/GJgpv3oh9TC4NcReMTK9aSc/jOzRmpxFNXCiTY+NZ/DyXy1 S40A87HEcrwbbkmhze3mFEwAap9tAbVmw08dP9XkWzgccNkxrsTowbReOeqeby/mvM21 fEzKCFnZJ81CiLiqMIoGU9PyN7Ueal0SW0gTwCiGdPgbjtDGmec83YSnR6pWyKwH7XLd wEVOgUeWcsPABnmVA2Y+SKfJGxFw2+JmdypJ5ClfPdz7OLttkve/TjyHBpdU5J/n+vtd YXWw== X-Gm-Message-State: AOAM5308RQW7iE2H+BWL6bkW5hcuB1P0Z4Mm9XlmibUPZIfgSHpZ2tAl o21/RknUcTEvQY/WUO1XibE= X-Google-Smtp-Source: ABdhPJyfL9kjLJ5laRAS5+b9JXqWdLH4UWSLPWaVE24ZUuM9BF3zE8Ke4dRt9cpQCFIksdK7gJHV4w== X-Received: by 2002:a62:c582:: with SMTP id j124mr10929426pfg.21.1597654668407; Mon, 17 Aug 2020 01:57:48 -0700 (PDT) Received: from localhost.localdomain ([49.207.202.98]) by smtp.gmail.com with ESMTPSA id j5sm19057245pfg.80.2020.08.17.01.57.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 17 Aug 2020 01:57:47 -0700 (PDT) From: Allen Pais To: perex@perex.cz, tiwai@suse.com, clemens@ladisch.de, o-takashi@sakamocchi.jp, timur@kernel.org, nicoleotsuka@gmail.com, Xiubo.Lee@gmail.com Subject: [PATCH 05/10] sound: rm9652: convert tasklets to use new tasklet_setup() API Date: Mon, 17 Aug 2020 14:26:58 +0530 Message-Id: <20200817085703.25732-6-allen.cryptic@gmail.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200817085703.25732-1-allen.cryptic@gmail.com> References: <20200817085703.25732-1-allen.cryptic@gmail.com> X-Mailman-Approved-At: Mon, 17 Aug 2020 11:17:21 +0200 Cc: alsa-devel@alsa-project.org, keescook@chromium.org, Allen Pais , linux-kernel@vger.kernel.org, Romain Perier , linuxppc-dev@lists.ozlabs.org X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" From: Allen Pais In preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly. Signed-off-by: Romain Perier Signed-off-by: Allen Pais --- sound/pci/rme9652/hdsp.c | 6 +++--- sound/pci/rme9652/hdspm.c | 7 +++---- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/sound/pci/rme9652/hdsp.c b/sound/pci/rme9652/hdsp.c index 227aece17e39..dda56ecfd33b 100644 --- a/sound/pci/rme9652/hdsp.c +++ b/sound/pci/rme9652/hdsp.c @@ -3791,9 +3791,9 @@ static int snd_hdsp_set_defaults(struct hdsp *hdsp) return 0; } -static void hdsp_midi_tasklet(unsigned long arg) +static void hdsp_midi_tasklet(struct tasklet_struct *t) { - struct hdsp *hdsp = (struct hdsp *)arg; + struct hdsp *hdsp = from_tasklet(hdsp, t, midi_tasklet); if (hdsp->midi[0].pending) snd_hdsp_midi_input_read (&hdsp->midi[0]); @@ -5182,7 +5182,7 @@ static int snd_hdsp_create(struct snd_card *card, spin_lock_init(&hdsp->lock); - tasklet_init(&hdsp->midi_tasklet, hdsp_midi_tasklet, (unsigned long)hdsp); + tasklet_setup(&hdsp->midi_tasklet, hdsp_midi_tasklet); pci_read_config_word(hdsp->pci, PCI_CLASS_REVISION, &hdsp->firmware_rev); hdsp->firmware_rev &= 0xff; diff --git a/sound/pci/rme9652/hdspm.c b/sound/pci/rme9652/hdspm.c index 0fa49f4d15cf..572350aaf18d 100644 --- a/sound/pci/rme9652/hdspm.c +++ b/sound/pci/rme9652/hdspm.c @@ -2169,9 +2169,9 @@ static int snd_hdspm_create_midi(struct snd_card *card, } -static void hdspm_midi_tasklet(unsigned long arg) +static void hdspm_midi_tasklet(struct tasklet_struct *t) { - struct hdspm *hdspm = (struct hdspm *)arg; + struct hdspm *hdspm = from_tasklet(hdspm, t, midi_tasklet); int i = 0; while (i < hdspm->midiPorts) { @@ -6836,8 +6836,7 @@ static int snd_hdspm_create(struct snd_card *card, } - tasklet_init(&hdspm->midi_tasklet, - hdspm_midi_tasklet, (unsigned long) hdspm); + tasklet_setup(&hdspm->midi_tasklet, hdspm_midi_tasklet); if (hdspm->io_type != MADIface) { From patchwork Mon Aug 17 08:57:00 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Allen Pais X-Patchwork-Id: 251405 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=-12.5 required=3.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, DKIM_VALID, FREEMAIL_FORGED_FROMDOMAIN, FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH, MAILING_LIST_MULTI, SIGNED_OFF_BY, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT autolearn=unavailable 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 71BE7C433DF for ; Mon, 17 Aug 2020 09:23:09 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id EEE852072D for ; Mon, 17 Aug 2020 09:23:08 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=alsa-project.org header.i=@alsa-project.org header.b="g4cnIHiZ"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="OyNFTefB" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org EEE852072D Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=alsa-devel-bounces@alsa-project.org Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 8CB8316B1; Mon, 17 Aug 2020 11:22:17 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 8CB8316B1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1597656187; bh=GFfAbFKZ1kPka9ZIhpFG5rPh420Kibyp3R9JkLhZrIE=; h=From:To:Subject:Date:In-Reply-To:References:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=g4cnIHiZYjVaVOe1AAFL6iY15XWMNOEfwUbxi+kRXUkh1PLA80Au2zhgz8yrj4NH6 Ofhe5H/M2PHm077bxfdKDIvaOlwwZoWU8aW5YYwPt3FwvNWiumauPqGQsJ8BgK2mLN Sfj1lBM/bk8ay6pIjORONiH0CIYg4Aq9EpLDnfR8= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 5B73EF802FD; Mon, 17 Aug 2020 11:17:31 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id BA526F80255; Mon, 17 Aug 2020 10:58:07 +0200 (CEST) Received: from mail-pl1-x644.google.com (mail-pl1-x644.google.com [IPv6:2607:f8b0:4864:20::644]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 9F88EF800EF for ; Mon, 17 Aug 2020 10:58:01 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 9F88EF800EF Authentication-Results: alsa1.perex.cz; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="OyNFTefB" Received: by mail-pl1-x644.google.com with SMTP id g7so6038345plq.1 for ; Mon, 17 Aug 2020 01:58:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=upmEUnhhDdxgVkgtOGQcHXFVgTj9nyWc06FqARMGISM=; b=OyNFTefB9dsBDrJk4+b3/O9xDgCkBGYAZEtl8e1sFe8eqB+0z37g1bXuaGh5Rz/mOV Vu9xGEY1MYjz55jhlzbwsAahCtRbdTz3TmGBn7sQxztPqM7rTG+RzjI3Oiny8RejrZuR CcmoL/IjRiGZ+ssZ2n0xgb+pW4Z6Lea77AxG5cveoSTlnxxqUI7fbOJagqytds6FoNFo 1itqsHARb9BlloVmjtqZv2KTHfwoy66YYWvv6YpBzgnvUwBIky4PzzfF4Ms719j3PL/i QUcVdpfYvYncsl7g9tvyZcNhfOVL8zhRmQ4Bm1y4PBi86/ARuEB3MdIQHbhmEwr5gUVt g9tQ== 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; bh=upmEUnhhDdxgVkgtOGQcHXFVgTj9nyWc06FqARMGISM=; b=gFsJ+3k/W/wnxI0v3zEcHewjn4muwGZms+WCXqDQMg0Y3/Bpl0CYa0dPYsDLsLu8nN iMV4Eojh9r/78uEaj+Yx3XmkdvBHZ+Aoc3nzjcgPDED8JWxAAbjB5xEhyODAWfBCGHux gi0E7+rp9Fj0cTKteuR3qc9o/qRU9woHb5MWSdrNszMPlXFLO/u/+tRCxeya6lj3rnpD c+BTidKhWgJgTFTtsaOHPMeJjx7vE0RFxtlzmuevkSSQTyu8TH/lSWKz/Nn0fnPwXmnR W1E68Q94tyyswsLQNic9CYxoUN/TOD2Jsd+7CrLqtnTdx5Ua8/ZpvnNIUKLiFaWXoLFv oeHA== X-Gm-Message-State: AOAM5309T8Xso62VxZB0bSSuOQ26I1k1SNWk+YMv+EP7XoB+IcTfDRtC d4oikNJvwAUmV0uBgTR+Ays= X-Google-Smtp-Source: ABdhPJy7woL4CHSE/M6HLZYby07kKJL7B6uvdb2M5oCEkFLXCvckJ3TLTnOJ9pzsBst4THF5+GoOoQ== X-Received: by 2002:a17:902:ee02:: with SMTP id z2mr10362445plb.291.1597654679016; Mon, 17 Aug 2020 01:57:59 -0700 (PDT) Received: from localhost.localdomain ([49.207.202.98]) by smtp.gmail.com with ESMTPSA id j5sm19057245pfg.80.2020.08.17.01.57.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 17 Aug 2020 01:57:58 -0700 (PDT) From: Allen Pais To: perex@perex.cz, tiwai@suse.com, clemens@ladisch.de, o-takashi@sakamocchi.jp, timur@kernel.org, nicoleotsuka@gmail.com, Xiubo.Lee@gmail.com Subject: [PATCH 07/10] sound/soc: sh: convert tasklets to use new tasklet_setup() API Date: Mon, 17 Aug 2020 14:27:00 +0530 Message-Id: <20200817085703.25732-8-allen.cryptic@gmail.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200817085703.25732-1-allen.cryptic@gmail.com> References: <20200817085703.25732-1-allen.cryptic@gmail.com> X-Mailman-Approved-At: Mon, 17 Aug 2020 11:17:21 +0200 Cc: alsa-devel@alsa-project.org, keescook@chromium.org, Allen Pais , linux-kernel@vger.kernel.org, Romain Perier , linuxppc-dev@lists.ozlabs.org X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" From: Allen Pais In preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly. Signed-off-by: Romain Perier Signed-off-by: Allen Pais --- sound/soc/sh/siu_pcm.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/sound/soc/sh/siu_pcm.c b/sound/soc/sh/siu_pcm.c index bd9de77c35f3..50fc7810723e 100644 --- a/sound/soc/sh/siu_pcm.c +++ b/sound/soc/sh/siu_pcm.c @@ -198,9 +198,9 @@ static int siu_pcm_rd_set(struct siu_port *port_info, return 0; } -static void siu_io_tasklet(unsigned long data) +static void siu_io_tasklet(struct tasklet_struct *t) { - struct siu_stream *siu_stream = (struct siu_stream *)data; + struct siu_stream *siu_stream = from_tasklet(siu_stream, t, tasklet); struct snd_pcm_substream *substream = siu_stream->substream; struct device *dev = substream->pcm->card->dev; struct snd_pcm_runtime *rt = substream->runtime; @@ -520,10 +520,8 @@ static int siu_pcm_new(struct snd_soc_component *component, (*port_info)->pcm = pcm; /* IO tasklets */ - tasklet_init(&(*port_info)->playback.tasklet, siu_io_tasklet, - (unsigned long)&(*port_info)->playback); - tasklet_init(&(*port_info)->capture.tasklet, siu_io_tasklet, - (unsigned long)&(*port_info)->capture); + tasklet_setup(&(*port_info)->playback.tasklet, siu_io_tasklet); + tasklet_setup(&(*port_info)->capture.tasklet, siu_io_tasklet); } dev_info(card->dev, "SuperH SIU driver initialized.\n"); From patchwork Mon Aug 17 08:57:02 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Allen Pais X-Patchwork-Id: 251404 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=-12.5 required=3.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, DKIM_VALID, FREEMAIL_FORGED_FROMDOMAIN, FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH, MAILING_LIST_MULTI, SIGNED_OFF_BY, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT autolearn=unavailable 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 B9C8DC433E1 for ; Mon, 17 Aug 2020 09:24:06 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 4041E207DF for ; Mon, 17 Aug 2020 09:24:06 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=alsa-project.org header.i=@alsa-project.org header.b="LV7rBDkY"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="M37L93SC" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 4041E207DF Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=alsa-devel-bounces@alsa-project.org Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id BE0601690; Mon, 17 Aug 2020 11:23:14 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz BE0601690 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1597656244; bh=/FaDgzSY/CPcabZMm/pyFSPS1b4zioKREWum67Uxt+4=; h=From:To:Subject:Date:In-Reply-To:References:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=LV7rBDkYeutFnn+fwltctYj19WU6TZAAjwvxjfp1Vux+RNkFf9EJWpNjsxU/G6N61 1woKWfpigfbKBwRZHCs9datzdcxyCVCy2s/EgQuJCNvhhr0CZr/ZUrxF+bZ7r0ALQg t8Dgth53srIP8VAc/7dKcjgtDNgG48OmxqRiHJY0= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 4BB69F80305; Mon, 17 Aug 2020 11:17:33 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 5C96DF80255; Mon, 17 Aug 2020 10:58:12 +0200 (CEST) Received: from mail-pj1-x1044.google.com (mail-pj1-x1044.google.com [IPv6:2607:f8b0:4864:20::1044]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 9528EF80218 for ; Mon, 17 Aug 2020 10:58:09 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 9528EF80218 Authentication-Results: alsa1.perex.cz; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="M37L93SC" Received: by mail-pj1-x1044.google.com with SMTP id e4so7503029pjd.0 for ; Mon, 17 Aug 2020 01:58:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=KccEtbXa6IlqeauaaaE7AIR0JNzfFLmA4P8zWKeg1Pc=; b=M37L93SCLVOuNTd2R9Itm92ayKxRQN2wHX1NMFvm06ygZB2w44PlvNXwkJzimpR6iB 2lXAZrOUVBZYUTzHKKHB25qNW2hykUMYhRfnT7q8KV7f7t8YxEzhRmbvf4l81mXIx4dw EPs6ufn++tfqVIgFjil8lKLw0yMOuqogI6PkT+GeHwVipcgtTdeVKXuM1PzVWiWcrfyL 6zWKzlQDXSZDv347qZKC4pSOvNznLe5RkWVehvvaP0bFYCd2H02PiYftk+J6+iY3wrEa vfgyjW7cXLAdOZUKrSj2k0LyCFiN4QXhoyxES3u+AwweLjEaKnkftQ99c8vxeyjYjdEK 609w== 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; bh=KccEtbXa6IlqeauaaaE7AIR0JNzfFLmA4P8zWKeg1Pc=; b=SJ+nzvG/Gq25KhKIUT9fLZGCyBXm/hziy8IHfy2i3voR1KMKrgducpCobQmr6T25F9 C/BlE0b2Cga7xqc9m5gyua9+K11oI91annoooVC+F5RdtQMYu6dj7NjKU3Itr0aR5qld kDFVmC44f+5Y9okXTjfwvz2+ANoCZcWaCwWM8Z/QbcS9UFqThoKmKr9YaIA3fg19LQ4c wDWZ27JZ0ue3FTB11e0LlVgRwD/6ZWOryQVT2EBXI0k5vP7Jn/O0ThVQSkBDEipSb3WK IUfU6QT5ey5wE20J4QFGxNH3CdkiqstcZ8i49yMuhUwAxQ8RbE3a2t3LrRAgnXcqJMx2 F44Q== X-Gm-Message-State: AOAM533qJ0dbmi0Xbnl4OdPSCDOqO0/HvBA9AWozSUTHaSj13Ed60v+u cGVNIRMkAYnEh2c736W7tq8= X-Google-Smtp-Source: ABdhPJzg9Sul/hHo2S3e13LeNtREGnuHKJS0d3HSemC0SzTDZO8mUsRC3gx5jqtsol6tC19JN8YCqA== X-Received: by 2002:a17:90b:1949:: with SMTP id nk9mr11123870pjb.185.1597654687567; Mon, 17 Aug 2020 01:58:07 -0700 (PDT) Received: from localhost.localdomain ([49.207.202.98]) by smtp.gmail.com with ESMTPSA id j5sm19057245pfg.80.2020.08.17.01.58.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 17 Aug 2020 01:58:07 -0700 (PDT) From: Allen Pais To: perex@perex.cz, tiwai@suse.com, clemens@ladisch.de, o-takashi@sakamocchi.jp, timur@kernel.org, nicoleotsuka@gmail.com, Xiubo.Lee@gmail.com Subject: [PATCH 09/10] sound: midi: convert tasklets to use new tasklet_setup() API Date: Mon, 17 Aug 2020 14:27:02 +0530 Message-Id: <20200817085703.25732-10-allen.cryptic@gmail.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200817085703.25732-1-allen.cryptic@gmail.com> References: <20200817085703.25732-1-allen.cryptic@gmail.com> X-Mailman-Approved-At: Mon, 17 Aug 2020 11:17:21 +0200 Cc: alsa-devel@alsa-project.org, keescook@chromium.org, Allen Pais , linux-kernel@vger.kernel.org, Romain Perier , linuxppc-dev@lists.ozlabs.org X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" From: Allen Pais In preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly. Signed-off-by: Romain Perier Signed-off-by: Allen Pais --- sound/usb/midi.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/sound/usb/midi.c b/sound/usb/midi.c index df639fe03118..e8287a05e36b 100644 --- a/sound/usb/midi.c +++ b/sound/usb/midi.c @@ -344,10 +344,9 @@ static void snd_usbmidi_do_output(struct snd_usb_midi_out_endpoint *ep) spin_unlock_irqrestore(&ep->buffer_lock, flags); } -static void snd_usbmidi_out_tasklet(unsigned long data) +static void snd_usbmidi_out_tasklet(struct tasklet_struct *t) { - struct snd_usb_midi_out_endpoint *ep = - (struct snd_usb_midi_out_endpoint *) data; + struct snd_usb_midi_out_endpoint *ep = from_tasklet(ep, t, tasklet); snd_usbmidi_do_output(ep); } @@ -1441,7 +1440,7 @@ static int snd_usbmidi_out_endpoint_create(struct snd_usb_midi *umidi, } spin_lock_init(&ep->buffer_lock); - tasklet_init(&ep->tasklet, snd_usbmidi_out_tasklet, (unsigned long)ep); + tasklet_setup(&ep->tasklet, snd_usbmidi_out_tasklet); init_waitqueue_head(&ep->drain_wait); for (i = 0; i < 0x10; ++i)