All of lore.kernel.org
 help / color / mirror / Atom feed
* Where to find constants for snd_magic_cast()
@ 2002-03-22 14:51 Kasparek Tomas
  2002-03-22 15:53 ` Takashi Iwai
  0 siblings, 1 reply; 2+ messages in thread
From: Kasparek Tomas @ 2002-03-22 14:51 UTC (permalink / raw)
  To: alsa-devel

Hi all,

Please, I tried to enable debugging for alsa-driver. For this I need to
add my own constants for snd_magic_cast(). How are these constants
construct and how this magic function works?

What is actual status of kernel API documentation. Sources are commented
poorly and there's no notice about kernel API documentation on web.
There are rummors about some information unofficialy released - could you
give me the direction, where to find these?

Thanks

--

	Tomas Kasparek (sioux, xkaspa06)
 	 Tomas.Kasparek@[seznam.cz,volny.cz]
	 Linux@dcse.fee.vutbr.cz
	student UIVT FEI VUT Brno


_______________________________________________
Alsa-devel mailing list
Alsa-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/alsa-devel

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

* Re: Where to find constants for snd_magic_cast()
  2002-03-22 14:51 Where to find constants for snd_magic_cast() Kasparek Tomas
@ 2002-03-22 15:53 ` Takashi Iwai
  0 siblings, 0 replies; 2+ messages in thread
From: Takashi Iwai @ 2002-03-22 15:53 UTC (permalink / raw)
  To: Kasparek Tomas; +Cc: alsa-devel

At Fri, 22 Mar 2002 15:51:31 +0100 (CET),
Kasparek Tomas wrote:
> 
> Hi all,
> 
> Please, I tried to enable debugging for alsa-driver. For this I need to
> add my own constants for snd_magic_cast(). How are these constants
> construct and how this magic function works?
 
you can define the constant as you like, although a kind of rule can
be easily found by looking through the numbers in sndmagic.h :)
just add your new type and increment the number.

magic functions check whether the pointer is valid, i.e. really
allocated via snd_magic_kmalloc().  it's good for a void pointer,
which type can not be known at the compile time.

please note that the buffer allocated via snd_magic_kmalloc must be
released via snd_magic_kfree(), not usual kfree().

> What is actual status of kernel API documentation. Sources are commented
> poorly and there's no notice about kernel API documentation on web.

no, there is none, so far.

> There are rummors about some information unofficialy released - could you
> give me the direction, where to find these?

i'd like to know if really there is one ;)


ciao,

Takashi

_______________________________________________
Alsa-devel mailing list
Alsa-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/alsa-devel

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

end of thread, other threads:[~2002-03-22 15:53 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-03-22 14:51 Where to find constants for snd_magic_cast() Kasparek Tomas
2002-03-22 15:53 ` Takashi Iwai

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.