Received: by 2002:ac0:aed5:0:0:0:0:0 with SMTP id t21csp3944264imb; Wed, 6 Mar 2019 01:10:35 -0800 (PST) X-Google-Smtp-Source: APXvYqxU/zreC4ZF+5sHC56edt9Hk60jvrIXhdMViBRZmRCqWCh9tI17TnOVyHykgQ4XGZyHiTMb X-Received: by 2002:a63:d449:: with SMTP id i9mr5399095pgj.449.1551863435123; Wed, 06 Mar 2019 01:10:35 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1551863435; cv=none; d=google.com; s=arc-20160816; b=fQdvQUGruvD6papGi5SS7r5DPRi1vuHpYpT4xHdTDmJprvWXMeQPZJFZEqay1Sb70T XAMWvkkprX8s7MLdVIzpp0w8y68w7GrghLRFlMM9qc949OLfFbVtF51CoEOhIur048rC bKLGNEAifY75mZi8PNClEjTf8wk5+PaUOhSkAR14D1cGX0DL6zcxhzjxEEQFxDaIMOsa WOZoBitJpieOlKp8MzU8vpkf8w6RJdoS0yie5YmfE9StUElhJFZ4/nsoSVmHkYixtCOZ a/n/n6YaCkb5DoHlPXIaXsuYb3+zroidagUKqadiIvzNmAb0ahbZvb/cHxQGXVQqCqXj MrWQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:to:content-transfer-encoding:mime-version :message-id:date:subject:cc:from:dkim-signature; bh=79l63kcqXmc25Kzf0CEDnWnX5vnRmUo9Cx6sRC5Sj+4=; b=vfPfhvhhowx3+OUQsh2W8N1s9UPw/PP7w4QwkHNYBmt2JGmkSlVO5r+vL204a2+rqY E1qPP9RWD9WrFYtU+dTGYhzJIQgnGFcEWW75BaOwwUMhUrAkdGPZuwfjMcUK6D4zKaa6 J026ldx6aDkkedbQsDdSmMZS9PPQpkwXda8+xg3XgdKt1N2Q/bTEaZMaJwp/NemgfZLR x5vywWKqZJMUqs/Q2V6NvkUzXQrUkiMiJVx7x1opsffaBLRLcuwbSaPgWs6Jwv27LQW7 6VLrMpuN+bUcms6/KprtNJwjAsLrXpl3W5C4KkBy53XbSsvOSjBKmmFHj71di5FsWKda DGug== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@chromium.org header.s=google header.b=TYePpk5h; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t18si948607pgv.285.2019.03.06.01.10.19; Wed, 06 Mar 2019 01:10:35 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@chromium.org header.s=google header.b=TYePpk5h; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729312AbfCFJJl (ORCPT + 99 others); Wed, 6 Mar 2019 04:09:41 -0500 Received: from mail-pf1-f193.google.com ([209.85.210.193]:37759 "EHLO mail-pf1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726391AbfCFJJk (ORCPT ); Wed, 6 Mar 2019 04:09:40 -0500 Received: by mail-pf1-f193.google.com with SMTP id s22so8074726pfh.4 for ; Wed, 06 Mar 2019 01:09:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=79l63kcqXmc25Kzf0CEDnWnX5vnRmUo9Cx6sRC5Sj+4=; b=TYePpk5hYtk7u634e/LJ7sQXvPICLPF9fzcwKbTZU4tiTR64l9GwO2qU+Of5hLYNu3 z6u0Z7chy1GtMQdkwlaXuVLWEaDV61CmPMl0yIxCQJWj+mUvitYwdsuz7wQq3ponzqeo 3gQxpQd2fLSFoGW4IxFOrEWqTK9/Z4fmKFEYs= 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:mime-version :content-transfer-encoding; bh=79l63kcqXmc25Kzf0CEDnWnX5vnRmUo9Cx6sRC5Sj+4=; b=uNaK34zNoAyqrMILH4A7xBUqbP6/BV0Kki+XhIeAne4c9Vb77fwJaeeAkPW922k7ca CzSvJzjGoLW+oHdnATIDSKoMrbMdSGyHQn6VwMj6Bq8RIc+TLe3Mej01zbC0tyYX+kET WLiiGaERfDouNpN+u+YvFiiy/nclNUG8YbcO6HVdaRDa4qiiD9hWDQ21vs6xp+wJoT2K krzgP9s87VxBOqy8EYm9u3SxFcLC79ERCfbYr83bYVbY2CCHhmeu+Pn49i60qhN+79rd IVddfGWkY2OCzxpDc3INGM2aXw8YWo0dWTRwFGeP1X0dM97i4Qiu84GcDflRDuqyXHDp pWJA== X-Gm-Message-State: APjAAAWto266aDqT+vLWgGYQbmNMhFK8o1yQTROJ8VB9VYxtEV+3HpV3 IV+wdZdSVUbgDkfgxtSxjsX7ng== X-Received: by 2002:a62:e0ca:: with SMTP id d71mr6198984pfm.62.1551863379887; Wed, 06 Mar 2019 01:09:39 -0800 (PST) Received: from pihsun-z840.tpe.corp.google.com ([2401:fa00:1:10:7889:7a43:f899:134c]) by smtp.googlemail.com with ESMTPSA id h65sm1603710pgc.93.2019.03.06.01.09.36 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 06 Mar 2019 01:09:39 -0800 (PST) From: Pi-Hsun Shih Cc: Pi-Hsun Shih , alsa-devel@alsa-project.org (moderated list:SOUND - SOC LAYER / DYNAMIC AUDIO POWER MANAGEM...), Garlic Tseng , KaiChieh Chuang , Kees Cook , linux-arm-kernel@lists.infradead.org (moderated list:ARM/Mediatek SoC support), linux-kernel@vger.kernel.org (open list), linux-mediatek@lists.infradead.org (moderated list:ARM/Mediatek SoC support), Mark Brown , Masanari Iida , Matthias Brugger , Rob Herring , Ryder Lee , Shunli Wang , Wei Yongjun Subject: [PATCH 0/2] Fix UBSAN warning in mtk-afe-fe-dai Date: Wed, 6 Mar 2019 17:09:01 +0800 Message-Id: <20190306090922.117634-1-pihsun@chromium.org> X-Mailer: git-send-email 2.21.0.352.gf09ad66450-goog MIME-Version: 1.0 Content-Transfer-Encoding: 8bit To: unlisted-recipients:; (no To-header on input) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This fix a UBSAN warning on mediatek mtk-afe-fe-dai, and also clean up code to prevent new config introduce the UBSAN warning again. Pi-Hsun Shih (2): ASoC: mediatek: Fix UBSAN warning. ASoC: mediatek: Reduce repititive code on mtk_regmap_update_bits. sound/soc/mediatek/common/mtk-afe-fe-dai.c | 51 +++++++++------------- sound/soc/mediatek/mt2701/mt2701-afe-pcm.c | 13 ------ sound/soc/mediatek/mt6797/mt6797-afe-pcm.c | 16 ------- sound/soc/mediatek/mt8173/mt8173-afe-pcm.c | 16 ------- sound/soc/mediatek/mt8183/mt8183-afe-pcm.c | 20 --------- 5 files changed, 20 insertions(+), 96 deletions(-) -- 2.21.0.352.gf09ad66450-goog