[alsa-devel] Building for 2.4 kernel..
Takashi Iwai
tiwai at suse.de
Mon Jan 21 14:35:42 CET 2008
At Sun, 20 Jan 2008 17:28:45 -0700,
marcus hall wrote:
>
> I support a product that is running the 2.4.18 linux kernel, and was trying
> to install alsa-driver-1.0.15, and ran into a problem.
>
> The alsa-kernel/pci/cs5535audio/cs5535audio_pm.c contains:
>
> if (pci_save_state(pci)) {
> ...
>
> and a similar line for pci_restore_state().
>
> But, in include/adriver.h, pci_save_state is #defined to
> snd_pci_compat_save_state, which is declared to return void, so the
> compiler complains that the void return isn't being ignored.
>
> Now, pci_save_state() appears to be supposed to return status, although
> in the 2.4 kernel at least, it returns a constant 0.
>
> Nevertheless, to get things to work, I changed snd_pci_compat_save_state(),
> snd_pci_orig_save_state(), and the corresponding restore functions to return
> an int with the following patch. (The other obvious solution would be to
> remove the test in cs5535audio_pm.c, but pci_save_state() is *supposed*
> to return an int...)
Thanks, applied to HG tree.
Takashi
More information about the Alsa-devel
mailing list