All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v1 1/1] ALSA: isa: Use INVALID_HWIRQ definition
@ 2022-07-15 20:57 ` Andy Shevchenko
  0 siblings, 0 replies; 7+ messages in thread
From: Andy Shevchenko @ 2022-07-15 20:57 UTC (permalink / raw)
  To: Takashi Iwai, alsa-devel, linux-kernel
  Cc: Jaroslav Kysela, Takashi Iwai, Andy Shevchenko

Use specific definition for invalid IRQ. It makes the
code uniform in respect to the constant used for that.
No functional change intended.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
 sound/isa/sscape.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/sound/isa/sscape.c b/sound/isa/sscape.c
index 0bc0025f7c19..9adaf91045e9 100644
--- a/sound/isa/sscape.c
+++ b/sound/isa/sscape.c
@@ -140,8 +140,7 @@ struct soundscape {
 	unsigned char midi_vol;
 };
 
-#define INVALID_IRQ  ((unsigned)-1)
-
+#define INVALID_IRQ  ((unsigned)INVALID_HWIRQ)
 
 static inline struct soundscape *get_card_soundscape(struct snd_card *c)
 {
-- 
2.35.1


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [PATCH v1 1/1] ALSA: isa: Use INVALID_HWIRQ definition
@ 2022-07-15 20:57 ` Andy Shevchenko
  0 siblings, 0 replies; 7+ messages in thread
From: Andy Shevchenko @ 2022-07-15 20:57 UTC (permalink / raw)
  To: Takashi Iwai, alsa-devel, linux-kernel; +Cc: Andy Shevchenko, Takashi Iwai

Use specific definition for invalid IRQ. It makes the
code uniform in respect to the constant used for that.
No functional change intended.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
 sound/isa/sscape.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/sound/isa/sscape.c b/sound/isa/sscape.c
index 0bc0025f7c19..9adaf91045e9 100644
--- a/sound/isa/sscape.c
+++ b/sound/isa/sscape.c
@@ -140,8 +140,7 @@ struct soundscape {
 	unsigned char midi_vol;
 };
 
-#define INVALID_IRQ  ((unsigned)-1)
-
+#define INVALID_IRQ  ((unsigned)INVALID_HWIRQ)
 
 static inline struct soundscape *get_card_soundscape(struct snd_card *c)
 {
-- 
2.35.1


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [PATCH v1 1/1] ALSA: isa: Use INVALID_HWIRQ definition
  2022-07-15 20:57 ` Andy Shevchenko
@ 2022-07-16  6:54   ` Takashi Iwai
  -1 siblings, 0 replies; 7+ messages in thread
From: Takashi Iwai @ 2022-07-16  6:54 UTC (permalink / raw)
  To: Andy Shevchenko; +Cc: alsa-devel, linux-kernel, Jaroslav Kysela, Takashi Iwai

On Fri, 15 Jul 2022 22:57:37 +0200,
Andy Shevchenko wrote:
> 
> Use specific definition for invalid IRQ. It makes the
> code uniform in respect to the constant used for that.
> No functional change intended.
> 
> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> ---
>  sound/isa/sscape.c | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/sound/isa/sscape.c b/sound/isa/sscape.c
> index 0bc0025f7c19..9adaf91045e9 100644
> --- a/sound/isa/sscape.c
> +++ b/sound/isa/sscape.c
> @@ -140,8 +140,7 @@ struct soundscape {
>  	unsigned char midi_vol;
>  };
>  
> -#define INVALID_IRQ  ((unsigned)-1)
> -
> +#define INVALID_IRQ  ((unsigned)INVALID_HWIRQ)
>  
>  static inline struct soundscape *get_card_soundscape(struct snd_card *c)
>  {

This seems failing to build on my local tree as is.
We need to include <linux/irq.h> explicitly.


thanks,

Takashi

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH v1 1/1] ALSA: isa: Use INVALID_HWIRQ definition
@ 2022-07-16  6:54   ` Takashi Iwai
  0 siblings, 0 replies; 7+ messages in thread
From: Takashi Iwai @ 2022-07-16  6:54 UTC (permalink / raw)
  To: Andy Shevchenko; +Cc: alsa-devel, Takashi Iwai, linux-kernel

On Fri, 15 Jul 2022 22:57:37 +0200,
Andy Shevchenko wrote:
> 
> Use specific definition for invalid IRQ. It makes the
> code uniform in respect to the constant used for that.
> No functional change intended.
> 
> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> ---
>  sound/isa/sscape.c | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/sound/isa/sscape.c b/sound/isa/sscape.c
> index 0bc0025f7c19..9adaf91045e9 100644
> --- a/sound/isa/sscape.c
> +++ b/sound/isa/sscape.c
> @@ -140,8 +140,7 @@ struct soundscape {
>  	unsigned char midi_vol;
>  };
>  
> -#define INVALID_IRQ  ((unsigned)-1)
> -
> +#define INVALID_IRQ  ((unsigned)INVALID_HWIRQ)
>  
>  static inline struct soundscape *get_card_soundscape(struct snd_card *c)
>  {

This seems failing to build on my local tree as is.
We need to include <linux/irq.h> explicitly.


thanks,

Takashi

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH v1 1/1] ALSA: isa: Use INVALID_HWIRQ definition
  2022-07-16  6:54   ` Takashi Iwai
@ 2022-07-18 19:14     ` Andy Shevchenko
  -1 siblings, 0 replies; 7+ messages in thread
From: Andy Shevchenko @ 2022-07-18 19:14 UTC (permalink / raw)
  To: Takashi Iwai; +Cc: alsa-devel, linux-kernel, Jaroslav Kysela, Takashi Iwai

On Sat, Jul 16, 2022 at 08:54:17AM +0200, Takashi Iwai wrote:
> On Fri, 15 Jul 2022 22:57:37 +0200,
> Andy Shevchenko wrote:

...

> > -#define INVALID_IRQ  ((unsigned)-1)
> > -
> > +#define INVALID_IRQ  ((unsigned)INVALID_HWIRQ)
> 
> This seems failing to build on my local tree as is.
> We need to include <linux/irq.h> explicitly.

As Marc told me this is probably the way to the wrong direction, so, please,
discard this patch anyway.

-- 
With Best Regards,
Andy Shevchenko



^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH v1 1/1] ALSA: isa: Use INVALID_HWIRQ definition
@ 2022-07-18 19:14     ` Andy Shevchenko
  0 siblings, 0 replies; 7+ messages in thread
From: Andy Shevchenko @ 2022-07-18 19:14 UTC (permalink / raw)
  To: Takashi Iwai; +Cc: alsa-devel, Takashi Iwai, linux-kernel

On Sat, Jul 16, 2022 at 08:54:17AM +0200, Takashi Iwai wrote:
> On Fri, 15 Jul 2022 22:57:37 +0200,
> Andy Shevchenko wrote:

...

> > -#define INVALID_IRQ  ((unsigned)-1)
> > -
> > +#define INVALID_IRQ  ((unsigned)INVALID_HWIRQ)
> 
> This seems failing to build on my local tree as is.
> We need to include <linux/irq.h> explicitly.

As Marc told me this is probably the way to the wrong direction, so, please,
discard this patch anyway.

-- 
With Best Regards,
Andy Shevchenko



^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH v1 1/1] ALSA: isa: Use INVALID_HWIRQ definition
@ 2022-07-16 17:42 kernel test robot
  0 siblings, 0 replies; 7+ messages in thread
From: kernel test robot @ 2022-07-16 17:42 UTC (permalink / raw)
  To: kbuild

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

:::::: 
:::::: Manual check reason: "commit no functional change"
:::::: 

CC: kbuild-all(a)lists.01.org
BCC: lkp(a)intel.com
In-Reply-To: <20220715205737.83076-1-andriy.shevchenko@linux.intel.com>
References: <20220715205737.83076-1-andriy.shevchenko@linux.intel.com>
TO: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
TO: Takashi Iwai <tiwai@suse.de>
TO: alsa-devel(a)alsa-project.org
TO: linux-kernel(a)vger.kernel.org
CC: Jaroslav Kysela <perex@perex.cz>
CC: Andy Shevchenko <andriy.shevchenko@linux.intel.com>

Hi Andy,

I love your patch! Yet something to improve:

[auto build test ERROR on tiwai-sound/for-next]
[also build test ERROR on linus/master v5.19-rc6 next-20220715]
[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#_base_tree_information]

url:    https://github.com/intel-lab-lkp/linux/commits/Andy-Shevchenko/ALSA-isa-Use-INVALID_HWIRQ-definition/20220716-230943
base:   https://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git for-next
:::::: branch date: 2 hours ago
:::::: commit date: 2 hours ago
config: i386-randconfig-a003 (https://download.01.org/0day-ci/archive/20220717/202207170129.eH1SH9ub-lkp(a)intel.com/config)
compiler: gcc-11 (Debian 11.3.0-3) 11.3.0
reproduce (this is a W=1 build):
        # https://github.com/intel-lab-lkp/linux/commit/6549abbad6209d1e2c60aa1ed28231649b5cffd8
        git remote add linux-review https://github.com/intel-lab-lkp/linux
        git fetch --no-tags linux-review Andy-Shevchenko/ALSA-isa-Use-INVALID_HWIRQ-definition/20220716-230943
        git checkout 6549abbad6209d1e2c60aa1ed28231649b5cffd8
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        make W=1 O=build_dir ARCH=i386 SHELL=/bin/bash

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

All errors (new ones prefixed by >>):

   sound/isa/sscape.c: In function 'get_irq_config':
>> sound/isa/sscape.c:143:33: error: 'INVALID_HWIRQ' undeclared (first use in this function); did you mean 'INVALID_IRQ'?
     143 | #define INVALID_IRQ  ((unsigned)INVALID_HWIRQ)
         |                                 ^~~~~~~~~~~~~
   sound/isa/sscape.c:678:16: note: in expansion of macro 'INVALID_IRQ'
     678 |         return INVALID_IRQ;
         |                ^~~~~~~~~~~
   sound/isa/sscape.c:143:33: note: each undeclared identifier is reported only once for each function it appears in
     143 | #define INVALID_IRQ  ((unsigned)INVALID_HWIRQ)
         |                                 ^~~~~~~~~~~~~
   sound/isa/sscape.c:678:16: note: in expansion of macro 'INVALID_IRQ'
     678 |         return INVALID_IRQ;
         |                ^~~~~~~~~~~
   sound/isa/sscape.c: In function 'create_sscape':
>> sound/isa/sscape.c:143:33: error: 'INVALID_HWIRQ' undeclared (first use in this function); did you mean 'INVALID_IRQ'?
     143 | #define INVALID_IRQ  ((unsigned)INVALID_HWIRQ)
         |                                 ^~~~~~~~~~~~~
   sound/isa/sscape.c:994:24: note: in expansion of macro 'INVALID_IRQ'
     994 |         if (irq_cfg == INVALID_IRQ) {
         |                        ^~~~~~~~~~~
   sound/isa/sscape.c: In function 'get_irq_config':
   sound/isa/sscape.c:679:1: error: control reaches end of non-void function [-Werror=return-type]
     679 | }
         | ^
   cc1: some warnings being treated as errors


vim +143 sound/isa/sscape.c

^1da177e4c3f41 Linus Torvalds  2005-04-16  142  
6549abbad6209d Andy Shevchenko 2022-07-15 @143  #define INVALID_IRQ  ((unsigned)INVALID_HWIRQ)
^1da177e4c3f41 Linus Torvalds  2005-04-16  144  

-- 
0-DAY CI Kernel Test Service
https://01.org/lkp

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2022-07-18 19:15 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-15 20:57 [PATCH v1 1/1] ALSA: isa: Use INVALID_HWIRQ definition Andy Shevchenko
2022-07-15 20:57 ` Andy Shevchenko
2022-07-16  6:54 ` Takashi Iwai
2022-07-16  6:54   ` Takashi Iwai
2022-07-18 19:14   ` Andy Shevchenko
2022-07-18 19:14     ` Andy Shevchenko
2022-07-16 17:42 kernel test robot

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.