projects
/
powerpc.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'master'
[powerpc.git]
/
sound
/
core
/
info.c
diff --git
a/sound/core/info.c
b/sound/core/info.c
index
5e122bb
..
39f9b97
100644
(file)
--- a/
sound/core/info.c
+++ b/
sound/core/info.c
@@
-295,7
+295,7
@@
static int snd_info_entry_open(struct inode *inode, struct file *file)
goto __error;
}
}
goto __error;
}
}
- data = k
calloc(1,
sizeof(*data), GFP_KERNEL);
+ data = k
zalloc(
sizeof(*data), GFP_KERNEL);
if (data == NULL) {
err = -ENOMEM;
goto __error;
if (data == NULL) {
err = -ENOMEM;
goto __error;
@@
-304,7
+304,7
@@
static int snd_info_entry_open(struct inode *inode, struct file *file)
switch (entry->content) {
case SNDRV_INFO_CONTENT_TEXT:
if (mode == O_RDONLY || mode == O_RDWR) {
switch (entry->content) {
case SNDRV_INFO_CONTENT_TEXT:
if (mode == O_RDONLY || mode == O_RDWR) {
- buffer = k
calloc(1,
sizeof(*buffer), GFP_KERNEL);
+ buffer = k
zalloc(
sizeof(*buffer), GFP_KERNEL);
if (buffer == NULL) {
kfree(data);
err = -ENOMEM;
if (buffer == NULL) {
kfree(data);
err = -ENOMEM;
@@
-323,7
+323,7
@@
static int snd_info_entry_open(struct inode *inode, struct file *file)
data->rbuffer = buffer;
}
if (mode == O_WRONLY || mode == O_RDWR) {
data->rbuffer = buffer;
}
if (mode == O_WRONLY || mode == O_RDWR) {
- buffer = k
calloc(1,
sizeof(*buffer), GFP_KERNEL);
+ buffer = k
zalloc(
sizeof(*buffer), GFP_KERNEL);
if (buffer == NULL) {
if (mode == O_RDWR) {
vfree(data->rbuffer->buffer);
if (buffer == NULL) {
if (mode == O_RDWR) {
vfree(data->rbuffer->buffer);
@@
-566,7
+566,6
@@
int __init snd_info_init(void)
}
#endif
snd_info_version_init();
}
#endif
snd_info_version_init();
- snd_memory_info_init();
snd_minor_info_init();
snd_minor_info_oss_init();
snd_card_info_init();
snd_minor_info_init();
snd_minor_info_oss_init();
snd_card_info_init();
@@
-578,7
+577,6
@@
int __exit snd_info_done(void)
snd_card_info_done();
snd_minor_info_oss_done();
snd_minor_info_done();
snd_card_info_done();
snd_minor_info_oss_done();
snd_minor_info_done();
- snd_memory_info_done();
snd_info_version_done();
if (snd_proc_root) {
#if defined(CONFIG_SND_SEQUENCER) || defined(CONFIG_SND_SEQUENCER_MODULE)
snd_info_version_done();
if (snd_proc_root) {
#if defined(CONFIG_SND_SEQUENCER) || defined(CONFIG_SND_SEQUENCER_MODULE)
@@
-702,7
+700,7
@@
int snd_info_get_line(snd_info_buffer_t * buffer, char *line, int len)
}
/**
}
/**
- * snd_info_get_
line
- parse a string token
+ * snd_info_get_
str
- parse a string token
* @dest: the buffer to store the string token
* @src: the original string
* @len: the max. length of token - 1
* @dest: the buffer to store the string token
* @src: the original string
* @len: the max. length of token - 1
@@
-752,7
+750,7
@@
char *snd_info_get_str(char *dest, char *src, int len)
static snd_info_entry_t *snd_info_create_entry(const char *name)
{
snd_info_entry_t *entry;
static snd_info_entry_t *snd_info_create_entry(const char *name)
{
snd_info_entry_t *entry;
- entry = k
calloc(1,
sizeof(*entry), GFP_KERNEL);
+ entry = k
zalloc(
sizeof(*entry), GFP_KERNEL);
if (entry == NULL)
return NULL;
entry->name = kstrdup(name, GFP_KERNEL);
if (entry == NULL)
return NULL;
entry->name = kstrdup(name, GFP_KERNEL);
@@
-939,7
+937,8
@@
int snd_info_unregister(snd_info_entry_t * entry)
{
struct proc_dir_entry *root;
{
struct proc_dir_entry *root;
- snd_assert(entry != NULL && entry->p != NULL, return -ENXIO);
+ snd_assert(entry != NULL, return -ENXIO);
+ snd_assert(entry->p != NULL, return -ENXIO);
root = entry->parent == NULL ? snd_proc_root : entry->parent->p;
snd_assert(root, return -ENXIO);
down(&info_mutex);
root = entry->parent == NULL ? snd_proc_root : entry->parent->p;
snd_assert(root, return -ENXIO);
down(&info_mutex);