All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: Re: [PATCH v5 5/5] drm/bridge: anx7625: add HDMI audio function
Date: Fri, 19 Mar 2021 12:09:23 +0800	[thread overview]
Message-ID: <202103191210.Rllrp6hZ-lkp@intel.com> (raw)
In-Reply-To: <0ee28b74edfaeb5b8047bade7c97988d6133b81b.1616071250.git.xji@analogixsemi.com>

[-- Attachment #1: Type: text/plain, Size: 5333 bytes --]

Hi Xin,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on robh/for-next]
[also build test WARNING on linux/master linus/master v5.12-rc3 next-20210318]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]

url:    https://github.com/0day-ci/linux/commits/Xin-Ji/Add-MIPI-rx-DPI-support/20210319-104013
base:   https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux.git for-next
config: s390-allyesconfig (attached as .config)
compiler: s390-linux-gcc (GCC) 9.3.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://github.com/0day-ci/linux/commit/ea2fa662ee036a3e1e2e25233653d7227b510b48
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review Xin-Ji/Add-MIPI-rx-DPI-support/20210319-104013
        git checkout ea2fa662ee036a3e1e2e25233653d7227b510b48
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=s390 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All warnings (new ones prefixed by >>):

>> drivers/gpu/drm/bridge/analogix/anx7625.c:1588:5: warning: no previous prototype for 'anx7625_audio_hw_params' [-Wmissing-prototypes]
    1588 | int anx7625_audio_hw_params(struct device *dev, void *data,
         |     ^~~~~~~~~~~~~~~~~~~~~~~


vim +/anx7625_audio_hw_params +1588 drivers/gpu/drm/bridge/analogix/anx7625.c

  1587	
> 1588	int anx7625_audio_hw_params(struct device *dev, void *data,
  1589				    struct hdmi_codec_daifmt *fmt,
  1590				    struct hdmi_codec_params *params)
  1591	{
  1592		struct anx7625_data *ctx = dev_get_drvdata(dev);
  1593		int wl, ch, rate;
  1594		int ret = 0;
  1595	
  1596		if (fmt->fmt != HDMI_DSP_A) {
  1597			DRM_DEV_ERROR(dev, "only supports DSP_A\n");
  1598			return -EINVAL;
  1599		}
  1600	
  1601		DRM_DEV_DEBUG_DRIVER(dev, "setting %d Hz, %d bit, %d channels\n",
  1602				     params->sample_rate, params->sample_width,
  1603				     params->cea.channels);
  1604	
  1605		ret |= anx7625_write_and_or(ctx, ctx->i2c.tx_p2_client,
  1606					    AUDIO_CHANNEL_STATUS_6,
  1607					    ~I2S_SLAVE_MODE,
  1608					    TDM_SLAVE_MODE);
  1609	
  1610		/* Word length */
  1611		switch (params->sample_width) {
  1612		case 16:
  1613			wl = AUDIO_W_LEN_16_20MAX;
  1614			break;
  1615		case 18:
  1616			wl = AUDIO_W_LEN_18_20MAX;
  1617			break;
  1618		case 20:
  1619			wl = AUDIO_W_LEN_20_20MAX;
  1620			break;
  1621		case 24:
  1622			wl = AUDIO_W_LEN_24_24MAX;
  1623			break;
  1624		default:
  1625			DRM_DEV_DEBUG_DRIVER(dev, "wordlength: %d bit not support",
  1626					     params->sample_width);
  1627			return -EINVAL;
  1628		}
  1629		ret |= anx7625_write_and_or(ctx, ctx->i2c.tx_p2_client,
  1630					    AUDIO_CHANNEL_STATUS_5,
  1631					    0xf0, wl);
  1632	
  1633		/* Channel num */
  1634		switch (params->cea.channels) {
  1635		case 2:
  1636			ch = I2S_CH_2;
  1637			break;
  1638		case 4:
  1639			ch = TDM_CH_4;
  1640			break;
  1641		case 6:
  1642			ch = TDM_CH_6;
  1643			break;
  1644		case 8:
  1645			ch = TDM_CH_8;
  1646			break;
  1647		default:
  1648			DRM_DEV_DEBUG_DRIVER(dev, "channel number: %d not support",
  1649					     params->cea.channels);
  1650			return -EINVAL;
  1651		}
  1652		ret |= anx7625_write_and_or(ctx, ctx->i2c.tx_p2_client,
  1653				       AUDIO_CHANNEL_STATUS_6, 0x1f, ch << 5);
  1654		if (ch > I2S_CH_2)
  1655			ret |= anx7625_write_or(ctx, ctx->i2c.tx_p2_client,
  1656					AUDIO_CHANNEL_STATUS_6, AUDIO_LAYOUT);
  1657		else
  1658			ret |= anx7625_write_and(ctx, ctx->i2c.tx_p2_client,
  1659					AUDIO_CHANNEL_STATUS_6, ~AUDIO_LAYOUT);
  1660	
  1661		/* FS */
  1662		switch (params->sample_rate) {
  1663		case 32000:
  1664			rate = AUDIO_FS_32K;
  1665			break;
  1666		case 44100:
  1667			rate = AUDIO_FS_441K;
  1668			break;
  1669		case 48000:
  1670			rate = AUDIO_FS_48K;
  1671			break;
  1672		case 88200:
  1673			rate = AUDIO_FS_882K;
  1674			break;
  1675		case 96000:
  1676			rate = AUDIO_FS_96K;
  1677			break;
  1678		case 176400:
  1679			rate = AUDIO_FS_1764K;
  1680			break;
  1681		case 192000:
  1682			rate = AUDIO_FS_192K;
  1683			break;
  1684		default:
  1685			DRM_DEV_DEBUG_DRIVER(dev, "sample rate: %d not support",
  1686					     params->sample_rate);
  1687			return -EINVAL;
  1688		}
  1689		ret |= anx7625_write_and_or(ctx, ctx->i2c.tx_p2_client,
  1690					    AUDIO_CHANNEL_STATUS_4,
  1691					    0xf0, rate);
  1692		ret |= anx7625_write_or(ctx, ctx->i2c.rx_p0_client,
  1693					AP_AV_STATUS, AP_AUDIO_CHG);
  1694		if (ret < 0) {
  1695			DRM_DEV_ERROR(dev, "IO error : config audio.\n");
  1696			return -EIO;
  1697		}
  1698	
  1699		return 0;
  1700	}
  1701	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 52367 bytes --]

  reply	other threads:[~2021-03-19  4:09 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-19  2:34 [PATCH v5 0/5] Add MIPI rx DPI support Xin Ji
2021-03-19  2:34 ` Xin Ji
2021-03-19  2:36 ` [PATCH v5 1/5] dt-bindings:drm/bridge:anx7625:add vendor define flags Xin Ji
2021-03-19  2:36   ` Xin Ji
2021-03-19  2:37 ` [PATCH v5 2/5] drm/bridge: anx7625: fix not correct return value Xin Ji
2021-03-19  2:37   ` Xin Ji
2021-03-19  2:37 ` [PATCH v5 3/5] drm/bridge: anx7625: add MIPI DPI input feature support Xin Ji
2021-03-19  2:37   ` Xin Ji
2021-03-19  4:44   ` kernel test robot
2021-03-19  2:38 ` [PATCH v5 4/5] drm/bridge: anx7625: add HDCP support Xin Ji
2021-03-19  2:38   ` Xin Ji
2021-03-19  2:39 ` [PATCH v5 5/5] drm/bridge: anx7625: add HDMI audio function Xin Ji
2021-03-19  2:39   ` Xin Ji
2021-03-19  4:09   ` kernel test robot [this message]
2021-03-19  4:52   ` kernel test robot
2021-03-19  4:52   ` [RFC PATCH] drm/bridge: anx7625: anx7625_audio_hw_params() can be static kernel test robot
2021-03-19  5:34   ` [PATCH v5 5/5] drm/bridge: anx7625: add HDMI audio function kernel test robot

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202103191210.Rllrp6hZ-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=kbuild-all@lists.01.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.