v6 patch series fixes
This commit is contained in:
parent
51dfafff5f
commit
d708eb3f65
|
|
@ -81,8 +81,7 @@ tascam_capture_pointer(struct snd_pcm_substream *substream)
|
|||
if (!atomic_read(&tascam->capture_active))
|
||||
return 0;
|
||||
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock)
|
||||
{
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock) {
|
||||
pos = tascam->capture_frames_processed;
|
||||
}
|
||||
|
||||
|
|
@ -179,8 +178,7 @@ void tascam_capture_work_handler(struct work_struct *work)
|
|||
size_t write_ptr, read_ptr, available_data;
|
||||
bool can_process;
|
||||
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock)
|
||||
{
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock) {
|
||||
write_ptr = tascam->capture_ring_buffer_write_ptr;
|
||||
read_ptr = tascam->capture_ring_buffer_read_ptr;
|
||||
available_data = (write_ptr >= read_ptr) ?
|
||||
|
|
@ -223,8 +221,7 @@ void tascam_capture_work_handler(struct work_struct *work)
|
|||
process_capture_routing_us144mkii(tascam, decoded_block,
|
||||
routed_block);
|
||||
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock)
|
||||
{
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock) {
|
||||
if (atomic_read(&tascam->capture_active)) {
|
||||
int f;
|
||||
|
||||
|
|
@ -280,8 +277,7 @@ void capture_urb_complete(struct urb *urb)
|
|||
goto out;
|
||||
|
||||
if (urb->actual_length > 0) {
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock)
|
||||
{
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock) {
|
||||
size_t write_ptr = tascam->capture_ring_buffer_write_ptr;
|
||||
size_t bytes_to_end = CAPTURE_RING_BUFFER_SIZE - write_ptr;
|
||||
|
||||
|
|
|
|||
|
|
@ -54,8 +54,7 @@ static int tascam_line_out_get(struct snd_kcontrol *kcontrol,
|
|||
{
|
||||
struct tascam_card *tascam = snd_kcontrol_chip(kcontrol);
|
||||
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock)
|
||||
{
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock) {
|
||||
ucontrol->value.enumerated.item[0] = tascam->line_out_source;
|
||||
}
|
||||
return 0;
|
||||
|
|
@ -81,8 +80,7 @@ static int tascam_line_out_put(struct snd_kcontrol *kcontrol,
|
|||
if (ucontrol->value.enumerated.item[0] > 1)
|
||||
return -EINVAL;
|
||||
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock)
|
||||
{
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock) {
|
||||
if (tascam->line_out_source != ucontrol->value.enumerated.item[0]) {
|
||||
tascam->line_out_source = ucontrol->value.enumerated.item[0];
|
||||
changed = 1;
|
||||
|
|
@ -125,8 +123,7 @@ static int tascam_digital_out_get(struct snd_kcontrol *kcontrol,
|
|||
{
|
||||
struct tascam_card *tascam = snd_kcontrol_chip(kcontrol);
|
||||
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock)
|
||||
{
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock) {
|
||||
ucontrol->value.enumerated.item[0] = tascam->digital_out_source;
|
||||
}
|
||||
return 0;
|
||||
|
|
@ -153,8 +150,7 @@ static int tascam_digital_out_put(struct snd_kcontrol *kcontrol,
|
|||
if (ucontrol->value.enumerated.item[0] > 1)
|
||||
return -EINVAL;
|
||||
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock)
|
||||
{
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock) {
|
||||
if (tascam->digital_out_source != ucontrol->value.enumerated.item[0]) {
|
||||
tascam->digital_out_source = ucontrol->value.enumerated.item[0];
|
||||
changed = 1;
|
||||
|
|
@ -215,8 +211,7 @@ static int tascam_capture_12_get(struct snd_kcontrol *kcontrol,
|
|||
{
|
||||
struct tascam_card *tascam = snd_kcontrol_chip(kcontrol);
|
||||
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock)
|
||||
{
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock) {
|
||||
ucontrol->value.enumerated.item[0] = tascam->capture_12_source;
|
||||
}
|
||||
return 0;
|
||||
|
|
@ -243,8 +238,7 @@ static int tascam_capture_12_put(struct snd_kcontrol *kcontrol,
|
|||
if (ucontrol->value.enumerated.item[0] > 1)
|
||||
return -EINVAL;
|
||||
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock)
|
||||
{
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock) {
|
||||
if (tascam->capture_12_source != ucontrol->value.enumerated.item[0]) {
|
||||
tascam->capture_12_source = ucontrol->value.enumerated.item[0];
|
||||
changed = 1;
|
||||
|
|
@ -288,8 +282,7 @@ static int tascam_capture_34_get(struct snd_kcontrol *kcontrol,
|
|||
{
|
||||
struct tascam_card *tascam = snd_kcontrol_chip(kcontrol);
|
||||
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock)
|
||||
{
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock) {
|
||||
ucontrol->value.enumerated.item[0] = tascam->capture_34_source;
|
||||
}
|
||||
return 0;
|
||||
|
|
@ -316,8 +309,7 @@ static int tascam_capture_34_put(struct snd_kcontrol *kcontrol,
|
|||
if (ucontrol->value.enumerated.item[0] > 1)
|
||||
return -EINVAL;
|
||||
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock)
|
||||
{
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock) {
|
||||
if (tascam->capture_34_source != ucontrol->value.enumerated.item[0]) {
|
||||
tascam->capture_34_source = ucontrol->value.enumerated.item[0];
|
||||
changed = 1;
|
||||
|
|
@ -385,8 +377,7 @@ static int tascam_samplerate_get(struct snd_kcontrol *kcontrol,
|
|||
int err;
|
||||
u32 rate = 0;
|
||||
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock)
|
||||
{
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock) {
|
||||
if (tascam->current_rate > 0) {
|
||||
ucontrol->value.integer.value[0] = tascam->current_rate;
|
||||
return 0;
|
||||
|
|
|
|||
|
|
@ -227,8 +227,7 @@ static void tascam_midi_out_work_handler(struct work_struct *work)
|
|||
u8 *buf;
|
||||
int bytes_to_send;
|
||||
|
||||
scoped_guard(spinlock_irqsave, &tascam->midi_out_lock)
|
||||
{
|
||||
scoped_guard(spinlock_irqsave, &tascam->midi_out_lock) {
|
||||
urb_index = -1;
|
||||
for (i = 0; i < NUM_MIDI_OUT_URBS; i++) {
|
||||
if (!test_bit(
|
||||
|
|
|
|||
|
|
@ -127,8 +127,7 @@ tascam_playback_pointer(struct snd_pcm_substream *substream)
|
|||
if (!atomic_read(&tascam->playback_active))
|
||||
return 0;
|
||||
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock)
|
||||
{
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock) {
|
||||
pos = tascam->playback_frames_consumed;
|
||||
}
|
||||
|
||||
|
|
@ -288,8 +287,7 @@ void feedback_urb_complete(struct urb *urb)
|
|||
capture_ss = tascam->capture_substream;
|
||||
capture_rt = capture_ss ? capture_ss->runtime : NULL;
|
||||
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock)
|
||||
{
|
||||
scoped_guard(spinlock_irqsave, &tascam->lock) {
|
||||
if (tascam->feedback_urb_skip_count > 0) {
|
||||
tascam->feedback_urb_skip_count--;
|
||||
break;
|
||||
|
|
|
|||
Loading…
Reference in New Issue