From: kbuild test robot <lkp@intel.com>
Cc: jgross@suse.com, alsa-devel@alsa-project.org,
Oleksandr Andrushchenko <oleksandr_andrushchenko@epam.com>,
andr2000@gmail.com, tiwai@suse.com, linux-kernel@vger.kernel.org,
perex@perex.cz, kbuild-all@01.org,
xen-devel@lists.xenproject.org, boris.ostrovsky@oracle.com
Subject: Re: [PATCH v2 5/5] ALSA: xen-front: Implement ALSA virtual sound driver
Date: Mon, 16 Apr 2018 22:59:34 +0800 [thread overview]
Message-ID: <201804162234.9q9gTZsC%fengguang.wu__45364.6080023192$1523890786$gmane$org@intel.com> (raw)
In-Reply-To: <20180416062453.24743-6-andr2000@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 23912 bytes --]
Hi Oleksandr,
Thank you for the patch! Yet something to improve:
[auto build test ERROR on sound/for-next]
[also build test ERROR on v4.17-rc1 next-20180416]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]
url: https://github.com/0day-ci/linux/commits/Oleksandr-Andrushchenko/ALSA-xen-front-Add-Xen-para-virtualized-frontend-driver/20180416-143123
base: https://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git for-next
config: x86_64-allmodconfig (attached as .config)
compiler: gcc-7 (Debian 7.3.0-1) 7.3.0
reproduce:
# save the attached .config to linux build tree
make ARCH=x86_64
All errors (new ones prefixed by >>):
sound/xen/xen_snd_front.c:70:46: sparse: undefined identifier 'XENSND_OP_HW_PARAM_QUERY'
sound/xen/xen_snd_front.c:71:16: sparse: no member 'hw_param' in union <unnamed>
sound/xen/xen_snd_front.c:105:21: sparse: no member 'period_sz' in struct xensnd_open_req
sound/xen/xen_snd_front.c:201:46: sparse: undefined identifier 'XENSND_OP_TRIGGER'
sound/xen/xen_snd_front.c:202:16: sparse: no member 'trigger' in union <unnamed>
sound/xen/xen_snd_front.c:70:36: sparse: call with no type!
sound/xen/xen_snd_front.c:71:16: sparse: generating address of non-lvalue (8)
sound/xen/xen_snd_front.c:105:21: sparse: generating address of non-lvalue (8)
sound/xen/xen_snd_front.c:201:36: sparse: call with no type!
In file included from sound/xen/xen_snd_front.c:23:0:
sound/xen/xen_snd_front_evtchnl.h:62:34: error: field 'hw_param' has incomplete type
struct xensnd_query_hw_param hw_param;
^~~~~~~~
sound/xen/xen_snd_front.c: In function 'xen_snd_front_stream_query_hw_param':
>> sound/xen/xen_snd_front.c:70:39: error: 'XENSND_OP_HW_PARAM_QUERY' undeclared (first use in this function); did you mean 'XENSND_OP_WRITE'?
req = be_stream_prepare_req(evtchnl, XENSND_OP_HW_PARAM_QUERY);
^~~~~~~~~~~~~~~~~~~~~~~~
XENSND_OP_WRITE
sound/xen/xen_snd_front.c:70:39: note: each undeclared identifier is reported only once for each function it appears in
>> sound/xen/xen_snd_front.c:71:9: error: 'union <anonymous>' has no member named 'hw_param'
req->op.hw_param = *hw_param_req;
^
>> sound/xen/xen_snd_front.c:71:21: error: dereferencing pointer to incomplete type 'struct xensnd_query_hw_param'
req->op.hw_param = *hw_param_req;
^~~~~~~~~~~~~
sound/xen/xen_snd_front.c: In function 'xen_snd_front_stream_prepare':
>> sound/xen/xen_snd_front.c:105:14: error: 'struct xensnd_open_req' has no member named 'period_sz'
req->op.open.period_sz = period_sz;
^
sound/xen/xen_snd_front.c: In function 'xen_snd_front_stream_trigger':
>> sound/xen/xen_snd_front.c:201:39: error: 'XENSND_OP_TRIGGER' undeclared (first use in this function); did you mean 'XENSND_OP_WRITE'?
req = be_stream_prepare_req(evtchnl, XENSND_OP_TRIGGER);
^~~~~~~~~~~~~~~~~
XENSND_OP_WRITE
>> sound/xen/xen_snd_front.c:202:9: error: 'union <anonymous>' has no member named 'trigger'
req->op.trigger.type = type;
^
--
sound/xen/xen_snd_front_alsa.c:191:47: sparse: restricted snd_pcm_format_t degrades to integer
sound/xen/xen_snd_front_alsa.c:205:59: sparse: restricted snd_pcm_format_t degrades to integer
sound/xen/xen_snd_front_alsa.c:266:12: sparse: using member 'formats' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:269:12: sparse: using member 'rates' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:270:12: sparse: using member 'rates' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:272:12: sparse: using member 'channels' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:273:12: sparse: using member 'channels' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:275:12: sparse: using member 'buffer' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:276:12: sparse: using member 'buffer' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:278:12: sparse: using member 'period' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:279:12: sparse: using member 'period' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:293:50: sparse: using member 'formats' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:306:28: sparse: using member 'rates' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:307:28: sparse: using member 'rates' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:313:28: sparse: using member 'channels' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:314:28: sparse: using member 'channels' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:320:28: sparse: using member 'buffer' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:321:28: sparse: using member 'buffer' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:327:28: sparse: using member 'period' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:328:28: sparse: using member 'period' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:509:24: sparse: undefined identifier 'XENSND_OP_TRIGGER_START'
sound/xen/xen_snd_front_alsa.c:513:24: sparse: undefined identifier 'XENSND_OP_TRIGGER_RESUME'
sound/xen/xen_snd_front_alsa.c:517:24: sparse: undefined identifier 'XENSND_OP_TRIGGER_STOP'
sound/xen/xen_snd_front_alsa.c:521:24: sparse: undefined identifier 'XENSND_OP_TRIGGER_PAUSE'
sound/xen/xen_snd_front_alsa.c:266:44: sparse: call with no type!
sound/xen/xen_snd_front_alsa.c:266:12: sparse: generating address of non-lvalue (8)
sound/xen/xen_snd_front_alsa.c:269:30: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:270:30: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:272:36: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:273:36: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:275:32: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:276:32: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:278:32: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:279:32: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:293:45: sparse: call with no type!
sound/xen/xen_snd_front_alsa.c:306:34: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:307:34: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:313:37: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:314:37: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:320:35: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:321:35: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:327:35: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:328:35: sparse: unknown expression (8 46)
In file included from sound/xen/xen_snd_front_alsa.c:22:0:
sound/xen/xen_snd_front_evtchnl.h:62:34: error: field 'hw_param' has incomplete type
struct xensnd_query_hw_param hw_param;
^~~~~~~~
sound/xen/xen_snd_front_alsa.c: In function 'alsa_hw_rule':
>> sound/xen/xen_snd_front_alsa.c:257:31: error: storage size of 'req' isn't known
struct xensnd_query_hw_param req;
^~~
>> sound/xen/xen_snd_front_alsa.c:258:31: error: storage size of 'resp' isn't known
struct xensnd_query_hw_param resp;
^~~~
sound/xen/xen_snd_front_alsa.c:258:31: warning: unused variable 'resp' [-Wunused-variable]
sound/xen/xen_snd_front_alsa.c:257:31: warning: unused variable 'req' [-Wunused-variable]
struct xensnd_query_hw_param req;
^~~
sound/xen/xen_snd_front_alsa.c: In function 'alsa_trigger':
>> sound/xen/xen_snd_front_alsa.c:509:10: error: 'XENSND_OP_TRIGGER_START' undeclared (first use in this function); did you mean 'SNDRV_PCM_TRIGGER_START'?
type = XENSND_OP_TRIGGER_START;
^~~~~~~~~~~~~~~~~~~~~~~
SNDRV_PCM_TRIGGER_START
sound/xen/xen_snd_front_alsa.c:509:10: note: each undeclared identifier is reported only once for each function it appears in
>> sound/xen/xen_snd_front_alsa.c:513:10: error: 'XENSND_OP_TRIGGER_RESUME' undeclared (first use in this function); did you mean 'XENSND_OP_TRIGGER_START'?
type = XENSND_OP_TRIGGER_RESUME;
^~~~~~~~~~~~~~~~~~~~~~~~
XENSND_OP_TRIGGER_START
>> sound/xen/xen_snd_front_alsa.c:517:10: error: 'XENSND_OP_TRIGGER_STOP' undeclared (first use in this function); did you mean 'XENSND_OP_TRIGGER_START'?
type = XENSND_OP_TRIGGER_STOP;
^~~~~~~~~~~~~~~~~~~~~~
XENSND_OP_TRIGGER_START
>> sound/xen/xen_snd_front_alsa.c:521:10: error: 'XENSND_OP_TRIGGER_PAUSE' undeclared (first use in this function); did you mean 'XENSND_OP_TRIGGER_RESUME'?
type = XENSND_OP_TRIGGER_PAUSE;
^~~~~~~~~~~~~~~~~~~~~~~
XENSND_OP_TRIGGER_RESUME
sparse warnings: (new ones prefixed by >>)
sound/xen/xen_snd_front.c:70:46: sparse: undefined identifier 'XENSND_OP_HW_PARAM_QUERY'
sound/xen/xen_snd_front.c:71:16: sparse: no member 'hw_param' in union <unnamed>
sound/xen/xen_snd_front.c:105:21: sparse: no member 'period_sz' in struct xensnd_open_req
sound/xen/xen_snd_front.c:201:46: sparse: undefined identifier 'XENSND_OP_TRIGGER'
sound/xen/xen_snd_front.c:202:16: sparse: no member 'trigger' in union <unnamed>
>> sound/xen/xen_snd_front.c:70:36: sparse: call with no type!
>> sound/xen/xen_snd_front.c:71:16: sparse: generating address of non-lvalue (8)
sound/xen/xen_snd_front.c:105:21: sparse: generating address of non-lvalue (8)
sound/xen/xen_snd_front.c:201:36: sparse: call with no type!
In file included from sound/xen/xen_snd_front.c:23:0:
sound/xen/xen_snd_front_evtchnl.h:62:34: error: field 'hw_param' has incomplete type
struct xensnd_query_hw_param hw_param;
^~~~~~~~
sound/xen/xen_snd_front.c: In function 'xen_snd_front_stream_query_hw_param':
sound/xen/xen_snd_front.c:70:39: error: 'XENSND_OP_HW_PARAM_QUERY' undeclared (first use in this function); did you mean 'XENSND_OP_WRITE'?
req = be_stream_prepare_req(evtchnl, XENSND_OP_HW_PARAM_QUERY);
^~~~~~~~~~~~~~~~~~~~~~~~
XENSND_OP_WRITE
sound/xen/xen_snd_front.c:70:39: note: each undeclared identifier is reported only once for each function it appears in
sound/xen/xen_snd_front.c:71:9: error: 'union <anonymous>' has no member named 'hw_param'
req->op.hw_param = *hw_param_req;
^
sound/xen/xen_snd_front.c:71:21: error: dereferencing pointer to incomplete type 'struct xensnd_query_hw_param'
req->op.hw_param = *hw_param_req;
^~~~~~~~~~~~~
sound/xen/xen_snd_front.c: In function 'xen_snd_front_stream_prepare':
sound/xen/xen_snd_front.c:105:14: error: 'struct xensnd_open_req' has no member named 'period_sz'
req->op.open.period_sz = period_sz;
^
sound/xen/xen_snd_front.c: In function 'xen_snd_front_stream_trigger':
sound/xen/xen_snd_front.c:201:39: error: 'XENSND_OP_TRIGGER' undeclared (first use in this function); did you mean 'XENSND_OP_WRITE'?
req = be_stream_prepare_req(evtchnl, XENSND_OP_TRIGGER);
^~~~~~~~~~~~~~~~~
XENSND_OP_WRITE
sound/xen/xen_snd_front.c:202:9: error: 'union <anonymous>' has no member named 'trigger'
req->op.trigger.type = type;
^
--
>> sound/xen/xen_snd_front_alsa.c:191:47: sparse: restricted snd_pcm_format_t degrades to integer
sound/xen/xen_snd_front_alsa.c:205:59: sparse: restricted snd_pcm_format_t degrades to integer
sound/xen/xen_snd_front_alsa.c:266:12: sparse: using member 'formats' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:269:12: sparse: using member 'rates' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:270:12: sparse: using member 'rates' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:272:12: sparse: using member 'channels' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:273:12: sparse: using member 'channels' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:275:12: sparse: using member 'buffer' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:276:12: sparse: using member 'buffer' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:278:12: sparse: using member 'period' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:279:12: sparse: using member 'period' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:293:50: sparse: using member 'formats' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:306:28: sparse: using member 'rates' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:307:28: sparse: using member 'rates' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:313:28: sparse: using member 'channels' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:314:28: sparse: using member 'channels' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:320:28: sparse: using member 'buffer' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:321:28: sparse: using member 'buffer' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:327:28: sparse: using member 'period' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:328:28: sparse: using member 'period' in incomplete struct xensnd_query_hw_param
sound/xen/xen_snd_front_alsa.c:509:24: sparse: undefined identifier 'XENSND_OP_TRIGGER_START'
sound/xen/xen_snd_front_alsa.c:513:24: sparse: undefined identifier 'XENSND_OP_TRIGGER_RESUME'
sound/xen/xen_snd_front_alsa.c:517:24: sparse: undefined identifier 'XENSND_OP_TRIGGER_STOP'
sound/xen/xen_snd_front_alsa.c:521:24: sparse: undefined identifier 'XENSND_OP_TRIGGER_PAUSE'
>> sound/xen/xen_snd_front_alsa.c:266:44: sparse: call with no type!
>> sound/xen/xen_snd_front_alsa.c:266:12: sparse: generating address of non-lvalue (8)
>> sound/xen/xen_snd_front_alsa.c:269:30: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:270:30: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:272:36: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:273:36: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:275:32: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:276:32: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:278:32: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:279:32: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:293:45: sparse: call with no type!
sound/xen/xen_snd_front_alsa.c:306:34: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:307:34: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:313:37: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:314:37: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:320:35: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:321:35: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:327:35: sparse: unknown expression (8 46)
sound/xen/xen_snd_front_alsa.c:328:35: sparse: unknown expression (8 46)
In file included from sound/xen/xen_snd_front_alsa.c:22:0:
sound/xen/xen_snd_front_evtchnl.h:62:34: error: field 'hw_param' has incomplete type
struct xensnd_query_hw_param hw_param;
^~~~~~~~
sound/xen/xen_snd_front_alsa.c: In function 'alsa_hw_rule':
sound/xen/xen_snd_front_alsa.c:257:31: error: storage size of 'req' isn't known
struct xensnd_query_hw_param req;
^~~
sound/xen/xen_snd_front_alsa.c:258:31: error: storage size of 'resp' isn't known
struct xensnd_query_hw_param resp;
^~~~
sound/xen/xen_snd_front_alsa.c:258:31: warning: unused variable 'resp' [-Wunused-variable]
sound/xen/xen_snd_front_alsa.c:257:31: warning: unused variable 'req' [-Wunused-variable]
struct xensnd_query_hw_param req;
^~~
sound/xen/xen_snd_front_alsa.c: In function 'alsa_trigger':
sound/xen/xen_snd_front_alsa.c:509:10: error: 'XENSND_OP_TRIGGER_START' undeclared (first use in this function); did you mean 'SNDRV_PCM_TRIGGER_START'?
type = XENSND_OP_TRIGGER_START;
^~~~~~~~~~~~~~~~~~~~~~~
SNDRV_PCM_TRIGGER_START
sound/xen/xen_snd_front_alsa.c:509:10: note: each undeclared identifier is reported only once for each function it appears in
sound/xen/xen_snd_front_alsa.c:513:10: error: 'XENSND_OP_TRIGGER_RESUME' undeclared (first use in this function); did you mean 'XENSND_OP_TRIGGER_START'?
type = XENSND_OP_TRIGGER_RESUME;
^~~~~~~~~~~~~~~~~~~~~~~~
XENSND_OP_TRIGGER_START
sound/xen/xen_snd_front_alsa.c:517:10: error: 'XENSND_OP_TRIGGER_STOP' undeclared (first use in this function); did you mean 'XENSND_OP_TRIGGER_START'?
type = XENSND_OP_TRIGGER_STOP;
^~~~~~~~~~~~~~~~~~~~~~
XENSND_OP_TRIGGER_START
sound/xen/xen_snd_front_alsa.c:521:10: error: 'XENSND_OP_TRIGGER_PAUSE' undeclared (first use in this function); did you mean 'XENSND_OP_TRIGGER_RESUME'?
type = XENSND_OP_TRIGGER_PAUSE;
^~~~~~~~~~~~~~~~~~~~~~~
XENSND_OP_TRIGGER_RESUME
vim +70 sound/xen/xen_snd_front.c
57
58 int xen_snd_front_stream_query_hw_param(struct xen_snd_front_evtchnl *evtchnl,
59 struct xensnd_query_hw_param *hw_param_req,
60 struct xensnd_query_hw_param *hw_param_resp)
61 {
62 struct xen_snd_front_info *front_info = evtchnl->front_info;
63 struct xensnd_req *req;
64 unsigned long flags;
65 int ret;
66
67 mutex_lock(&evtchnl->u.req.req_io_lock);
68
69 spin_lock_irqsave(&front_info->io_lock, flags);
> 70 req = be_stream_prepare_req(evtchnl, XENSND_OP_HW_PARAM_QUERY);
> 71 req->op.hw_param = *hw_param_req;
72
73 ret = be_stream_do_io(evtchnl);
74 spin_unlock_irqrestore(&front_info->io_lock, flags);
75
76 if (ret == 0)
77 ret = be_stream_wait_io(evtchnl);
78
79 if (ret == 0)
80 *hw_param_resp = evtchnl->u.req.resp.hw_param;
81
82 mutex_unlock(&evtchnl->u.req.req_io_lock);
83 return ret;
84 }
85
86 int xen_snd_front_stream_prepare(struct xen_snd_front_evtchnl *evtchnl,
87 struct xen_snd_front_shbuf *sh_buf,
88 u8 format, unsigned int channels,
89 unsigned int rate, u32 buffer_sz,
90 u32 period_sz)
91 {
92 struct xen_snd_front_info *front_info = evtchnl->front_info;
93 struct xensnd_req *req;
94 unsigned long flags;
95 int ret;
96
97 mutex_lock(&evtchnl->u.req.req_io_lock);
98
99 spin_lock_irqsave(&front_info->io_lock, flags);
100 req = be_stream_prepare_req(evtchnl, XENSND_OP_OPEN);
101 req->op.open.pcm_format = format;
102 req->op.open.pcm_channels = channels;
103 req->op.open.pcm_rate = rate;
104 req->op.open.buffer_sz = buffer_sz;
> 105 req->op.open.period_sz = period_sz;
106 req->op.open.gref_directory = xen_snd_front_shbuf_get_dir_start(sh_buf);
107
108 ret = be_stream_do_io(evtchnl);
109 spin_unlock_irqrestore(&front_info->io_lock, flags);
110
111 if (ret == 0)
112 ret = be_stream_wait_io(evtchnl);
113
114 mutex_unlock(&evtchnl->u.req.req_io_lock);
115 return ret;
116 }
117
118 int xen_snd_front_stream_close(struct xen_snd_front_evtchnl *evtchnl)
119 {
120 struct xen_snd_front_info *front_info = evtchnl->front_info;
121 struct xensnd_req *req;
122 unsigned long flags;
123 int ret;
124
125 mutex_lock(&evtchnl->u.req.req_io_lock);
126
127 spin_lock_irqsave(&front_info->io_lock, flags);
128 req = be_stream_prepare_req(evtchnl, XENSND_OP_CLOSE);
129
130 ret = be_stream_do_io(evtchnl);
131 spin_unlock_irqrestore(&front_info->io_lock, flags);
132
133 if (ret == 0)
134 ret = be_stream_wait_io(evtchnl);
135
136 mutex_unlock(&evtchnl->u.req.req_io_lock);
137 return ret;
138 }
139
140 int xen_snd_front_stream_write(struct xen_snd_front_evtchnl *evtchnl,
141 unsigned long pos, unsigned long count)
142 {
143 struct xen_snd_front_info *front_info = evtchnl->front_info;
144 struct xensnd_req *req;
145 unsigned long flags;
146 int ret;
147
148 mutex_lock(&evtchnl->u.req.req_io_lock);
149
150 spin_lock_irqsave(&front_info->io_lock, flags);
151 req = be_stream_prepare_req(evtchnl, XENSND_OP_WRITE);
152 req->op.rw.length = count;
153 req->op.rw.offset = pos;
154
155 ret = be_stream_do_io(evtchnl);
156 spin_unlock_irqrestore(&front_info->io_lock, flags);
157
158 if (ret == 0)
159 ret = be_stream_wait_io(evtchnl);
160
161 mutex_unlock(&evtchnl->u.req.req_io_lock);
162 return ret;
163 }
164
165 int xen_snd_front_stream_read(struct xen_snd_front_evtchnl *evtchnl,
166 unsigned long pos, unsigned long count)
167 {
168 struct xen_snd_front_info *front_info = evtchnl->front_info;
169 struct xensnd_req *req;
170 unsigned long flags;
171 int ret;
172
173 mutex_lock(&evtchnl->u.req.req_io_lock);
174
175 spin_lock_irqsave(&front_info->io_lock, flags);
176 req = be_stream_prepare_req(evtchnl, XENSND_OP_READ);
177 req->op.rw.length = count;
178 req->op.rw.offset = pos;
179
180 ret = be_stream_do_io(evtchnl);
181 spin_unlock_irqrestore(&front_info->io_lock, flags);
182
183 if (ret == 0)
184 ret = be_stream_wait_io(evtchnl);
185
186 mutex_unlock(&evtchnl->u.req.req_io_lock);
187 return ret;
188 }
189
190 int xen_snd_front_stream_trigger(struct xen_snd_front_evtchnl *evtchnl,
191 int type)
192 {
193 struct xen_snd_front_info *front_info = evtchnl->front_info;
194 struct xensnd_req *req;
195 unsigned long flags;
196 int ret;
197
198 mutex_lock(&evtchnl->u.req.req_io_lock);
199
200 spin_lock_irqsave(&front_info->io_lock, flags);
> 201 req = be_stream_prepare_req(evtchnl, XENSND_OP_TRIGGER);
> 202 req->op.trigger.type = type;
203
204 ret = be_stream_do_io(evtchnl);
205 spin_unlock_irqrestore(&front_info->io_lock, flags);
206
207 if (ret == 0)
208 ret = be_stream_wait_io(evtchnl);
209
210 mutex_unlock(&evtchnl->u.req.req_io_lock);
211 return ret;
212 }
213
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 62903 bytes --]
[-- Attachment #3: Type: text/plain, Size: 157 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel
next prev parent reply other threads:[~2018-04-16 15:00 UTC|newest]
Thread overview: 91+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-04-16 6:24 [PATCH v2 0/5] ALSA: xen-front: Add Xen para-virtualized frontend driver Oleksandr Andrushchenko
2018-04-16 6:24 ` [PATCH v2 1/5] ALSA: xen-front: Introduce Xen para-virtualized sound " Oleksandr Andrushchenko
2018-04-16 12:25 ` Juergen Gross
2018-04-17 8:24 ` Oleksandr Andrushchenko
2018-04-17 8:24 ` Oleksandr Andrushchenko
2018-04-16 12:25 ` Juergen Gross
2018-04-24 13:55 ` Takashi Iwai
2018-04-24 13:55 ` Takashi Iwai
2018-04-24 13:59 ` Oleksandr Andrushchenko
2018-04-24 13:59 ` Oleksandr Andrushchenko
2018-04-24 13:59 ` Oleksandr Andrushchenko
2018-04-24 13:55 ` Takashi Iwai
2018-04-16 6:24 ` Oleksandr Andrushchenko
2018-04-16 6:24 ` [PATCH v2 2/5] ALSA: xen-front: Read sound driver configuration from Xen store Oleksandr Andrushchenko
2018-04-16 6:24 ` Oleksandr Andrushchenko
2018-04-16 12:55 ` Juergen Gross
2018-04-17 8:42 ` Oleksandr Andrushchenko
2018-04-17 8:42 ` Oleksandr Andrushchenko
2018-04-17 11:08 ` Juergen Gross
2018-04-17 11:08 ` Juergen Gross
2018-04-16 12:55 ` Juergen Gross
2018-04-16 6:24 ` [PATCH v2 3/5] ALSA: xen-front: Implement Xen event channel handling Oleksandr Andrushchenko
2018-04-16 6:24 ` Oleksandr Andrushchenko
2018-04-16 13:12 ` Juergen Gross
2018-04-16 13:12 ` Juergen Gross
2018-04-17 8:58 ` Oleksandr Andrushchenko
2018-04-17 11:14 ` Juergen Gross
2018-04-17 11:21 ` Oleksandr Andrushchenko
2018-04-17 11:21 ` Oleksandr Andrushchenko
2018-04-17 11:14 ` Juergen Gross
2018-04-17 8:58 ` Oleksandr Andrushchenko
2018-04-16 13:53 ` kbuild test robot
2018-04-16 13:53 ` kbuild test robot
2018-04-16 13:53 ` kbuild test robot
2018-04-24 14:20 ` Takashi Iwai
2018-04-24 14:20 ` Takashi Iwai
2018-04-24 14:29 ` Oleksandr Andrushchenko
2018-04-24 14:29 ` Oleksandr Andrushchenko
2018-04-24 14:35 ` Takashi Iwai
2018-04-24 14:35 ` Takashi Iwai
2018-04-24 14:58 ` Oleksandr Andrushchenko
2018-04-24 14:58 ` Oleksandr Andrushchenko
2018-04-24 15:02 ` Takashi Iwai
2018-04-24 15:02 ` Takashi Iwai
2018-04-24 16:23 ` Oleksandr Andrushchenko
2018-04-24 16:23 ` Oleksandr Andrushchenko
2018-04-24 16:23 ` Oleksandr Andrushchenko
2018-04-25 8:26 ` Oleksandr Andrushchenko
2018-04-25 8:26 ` Oleksandr Andrushchenko
2018-04-25 8:26 ` Oleksandr Andrushchenko
2018-04-25 9:02 ` Takashi Iwai
2018-04-25 9:02 ` Takashi Iwai
2018-04-25 9:04 ` Oleksandr Andrushchenko
2018-04-25 9:04 ` Oleksandr Andrushchenko
2018-04-25 9:04 ` Oleksandr Andrushchenko
2018-04-25 9:02 ` Takashi Iwai
2018-04-24 14:58 ` Oleksandr Andrushchenko
2018-04-24 14:35 ` Takashi Iwai
2018-04-24 14:20 ` Takashi Iwai
2018-04-16 6:24 ` [PATCH v2 4/5] ALSA: xen-front: Implement handling of shared buffers Oleksandr Andrushchenko
2018-04-16 13:39 ` Juergen Gross
2018-04-17 9:22 ` Oleksandr Andrushchenko
2018-04-17 9:22 ` Oleksandr Andrushchenko
2018-04-17 11:15 ` Juergen Gross
2018-04-17 11:15 ` Juergen Gross
2018-04-16 13:39 ` Juergen Gross
2018-04-16 6:24 ` Oleksandr Andrushchenko
2018-04-16 6:24 ` [PATCH v2 5/5] ALSA: xen-front: Implement ALSA virtual sound driver Oleksandr Andrushchenko
2018-04-16 6:24 ` Oleksandr Andrushchenko
2018-04-16 14:09 ` Juergen Gross
2018-04-16 14:09 ` Juergen Gross
2018-04-17 11:32 ` Oleksandr Andrushchenko
2018-04-17 12:26 ` Oleksandr Andrushchenko
2018-04-17 12:32 ` Juergen Gross
2018-04-17 12:32 ` Juergen Gross
2018-04-17 12:34 ` Oleksandr Andrushchenko
2018-04-17 12:34 ` Oleksandr Andrushchenko
2018-04-17 12:34 ` Oleksandr Andrushchenko
2018-04-17 12:26 ` Oleksandr Andrushchenko
2018-04-17 11:32 ` Oleksandr Andrushchenko
2018-04-16 14:59 ` kbuild test robot [this message]
2018-04-16 14:59 ` kbuild test robot
2018-04-16 14:59 ` kbuild test robot
2018-04-17 12:42 ` [PATCH v2 0/5] ALSA: xen-front: Add Xen para-virtualized frontend driver Oleksandr Andrushchenko
2018-04-17 12:42 ` Oleksandr Andrushchenko
2018-04-18 15:15 ` Oleksandr Andrushchenko
2018-04-18 15:15 ` Oleksandr Andrushchenko
2018-04-23 6:34 ` Oleksandr Andrushchenko
2018-04-23 6:34 ` Oleksandr Andrushchenko
2018-05-02 7:59 ` Oleksandr Andrushchenko
2018-05-02 7:59 ` Oleksandr Andrushchenko
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='201804162234.9q9gTZsC%fengguang.wu__45364.6080023192$1523890786$gmane$org@intel.com' \
--to=lkp@intel.com \
--cc=alsa-devel@alsa-project.org \
--cc=andr2000@gmail.com \
--cc=boris.ostrovsky@oracle.com \
--cc=jgross@suse.com \
--cc=kbuild-all@01.org \
--cc=linux-kernel@vger.kernel.org \
--cc=oleksandr_andrushchenko@epam.com \
--cc=perex@perex.cz \
--cc=tiwai@suse.com \
--cc=xen-devel@lists.xenproject.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.