Skip to content
  • Takashi Iwai's avatar
    ALSA: Add a helper to add a new attribute group to card · 6bbc7fed
    Takashi Iwai authored
    
    
    For assigning sysfs entries for a card device from the driver,
    introduce a new helper function, snd_card_add_dev_attr().  In this
    way, we can avoid the possible race between the device registration
    and the sysfs addition / removal.
    
    The driver can pass a new attribute group to add freely.  This has to
    be called before snd_card_register().
    
    Currently, up to two extra groups can be added.  More than that, it'll
    return an error.
    
    Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
    6bbc7fed