Lines Matching +full:entry +full:- +full:address
1 // SPDX-License-Identifier: GPL-2.0-or-later
14 unsigned int address; member
19 static ssize_t snd_gf1_mem_proc_dump(struct snd_info_entry *entry, in snd_gf1_mem_proc_dump() argument
24 struct gus_proc_private *priv = entry->private_data; in snd_gf1_mem_proc_dump()
25 struct snd_gus_card *gus = priv->gus; in snd_gf1_mem_proc_dump()
28 err = snd_gus_dram_read(gus, buf, pos, count, priv->rom); in snd_gf1_mem_proc_dump()
34 static void snd_gf1_mem_proc_free(struct snd_info_entry *entry) in snd_gf1_mem_proc_free() argument
36 struct gus_proc_private *priv = entry->private_data; in snd_gf1_mem_proc_free()
49 struct snd_info_entry *entry; in snd_gf1_mem_proc_init() local
52 if (gus->gf1.mem_alloc.banks_8[idx].size > 0) { in snd_gf1_mem_proc_init()
55 return -ENOMEM; in snd_gf1_mem_proc_init()
56 priv->gus = gus; in snd_gf1_mem_proc_init()
57 sprintf(name, "gus-ram-%i", idx); in snd_gf1_mem_proc_init()
58 if (! snd_card_proc_new(gus->card, name, &entry)) { in snd_gf1_mem_proc_init()
59 entry->content = SNDRV_INFO_CONTENT_DATA; in snd_gf1_mem_proc_init()
60 entry->private_data = priv; in snd_gf1_mem_proc_init()
61 entry->private_free = snd_gf1_mem_proc_free; in snd_gf1_mem_proc_init()
62 entry->c.ops = &snd_gf1_mem_proc_ops; in snd_gf1_mem_proc_init()
63 priv->address = gus->gf1.mem_alloc.banks_8[idx].address; in snd_gf1_mem_proc_init()
64 priv->size = entry->size = gus->gf1.mem_alloc.banks_8[idx].size; in snd_gf1_mem_proc_init()
69 if (gus->gf1.rom_present & (1 << idx)) { in snd_gf1_mem_proc_init()
72 return -ENOMEM; in snd_gf1_mem_proc_init()
73 priv->rom = 1; in snd_gf1_mem_proc_init()
74 priv->gus = gus; in snd_gf1_mem_proc_init()
75 sprintf(name, "gus-rom-%i", idx); in snd_gf1_mem_proc_init()
76 if (! snd_card_proc_new(gus->card, name, &entry)) { in snd_gf1_mem_proc_init()
77 entry->content = SNDRV_INFO_CONTENT_DATA; in snd_gf1_mem_proc_init()
78 entry->private_data = priv; in snd_gf1_mem_proc_init()
79 entry->private_free = snd_gf1_mem_proc_free; in snd_gf1_mem_proc_init()
80 entry->c.ops = &snd_gf1_mem_proc_ops; in snd_gf1_mem_proc_init()
81 priv->address = idx * 4096 * 1024; in snd_gf1_mem_proc_init()
82 priv->size = entry->size = gus->gf1.rom_memory; in snd_gf1_mem_proc_init()