First set of Counter fixes for 6.0
Subsystems (3)
cover First set of Counter fixes for 6.0
This is the same as the earlier pull request [0] but as a patch series here instead.
There's nothing particularly special here: just a patch fixing a bug in 104-quad-8, and another realigning some comment blocks.
[0] https://lore.kernel.org/r/YyNWADWgfl1sL10S@ishi/
William Breathitt Gray (2):
counter: 104-quad-8: Fix skipped IRQ lines during events configuration
counter: Realign counter_comp comment block to 80 characters
drivers/counter/104-quad-8.c | 6 +++--- include/linux/counter.h | 40 ++++++++++++++++++------------------ 2 files changed, 23 insertions(+), 23 deletions(-)
base-commit: 568035b01cfb107af8d2e4bd2fb9aea22cf5b868
Signature · 1 line
2.37.3
PATCH 1/2 counter: 104-quad-8: Fix skipped IRQ lines during events configuration
IRQ trigger configuration is skipped if it has already been set before; however, the IRQ line still needs to be OR'd to irq_enabled because irq_enabled is reset for every events_configure call. This patch moves the irq_enabled OR operation update to before the irq_trigger check so that IRQ line enablement is not skipped.
--- drivers/counter/104-quad-8.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/counter/104-quad-8.c +3 -3
@@ -449,6 +449,9 @@ static int quad8_events_configure(struct counter_device *counter)return -EINVAL ; } +/* Enable IRQ line */ + irq_enabled |=BIT (event_node->channel); +/* Skip configuration if it is the same as previously set */ if (priv->irq_trigger[event_node->channel] == next_irq_trigger)continue ;
@@ -462,9 +465,6 @@ static int quad8_events_configure(struct counter_device *counter) priv->irq_trigger[event_node->channel] <<3 ;iowrite8 (QUAD8_CTR_IOR | ior_cfg, &priv->reg->channel[event_node->channel].control); - -/* Enable IRQ line */ - irq_enabled |=BIT (event_node->channel); }iowrite8 (irq_enabled, &priv->reg->index_interrupt);
Signature · 1 line
2.37.3
Re: [PATCH 1/2] counter: 104-quad-8: Fix skipped IRQ lines during events configuration
Quoted 9 lines · William Breathitt Gray
IRQ trigger configuration is skipped if it has already been set before; however, the IRQ line still needs to be OR'd to
irq_enabledbecauseirq_enabledis reset for everyevents_configurecall. This patch moves theirq_enabledOR operation update to before theirq_triggercheck so that IRQ line enablement is not skipped.Fixes c95cc0d95702 ("counter: 104-quad-8: Fix persistent enabled events bug")Signed-off-by William Breathitt Gray <[email protected]>
This should have also cc: stable. I'll add that when I apply it, thanks.
greg k-h
PATCH 2/2 counter: Realign counter_comp comment block to 80 characters
In reply to William Breathitt GrayThe member documentation comment lines for struct counter_comp extend past the 80-characters column boundary due to extra identation at the start of each section. This patch realigns the comment block within the 80-characters boundary by removing these superfluous indents.
--- include/linux/counter.h | 40 ++++++++++++++++++++-------------------- 1 file changed, 20 insertions(+), 20 deletions(-)
include/linux/counter.h +20 -20
@@ -38,64 +38,64 @@ enum counter_comp_type {* @type: Counter component data type * @name: device-specific component name * @priv: component-relevant data -* @action_read: Synapse action mode read callback. The read value of the +* @action_read: Synapse action mode read callback. The read value of the * respective Synapse action mode should be passed back via * the action parameter. -* @device_u8_read: Device u8 component read callback. The read value of the +* @device_u8_read: Device u8 component read callback. The read value of the * respective Device u8 component should be passed back via * the val parameter. -* @count_u8_read: Count u8 component read callback. The read value of the +* @count_u8_read: Count u8 component read callback. The read value of the * respective Count u8 component should be passed back via * the val parameter. -* @signal_u8_read: Signal u8 component read callback. The read value of the +* @signal_u8_read: Signal u8 component read callback. The read value of the * respective Signal u8 component should be passed back via * the val parameter. -* @device_u32_read: Device u32 component read callback. The read value of +* @device_u32_read: Device u32 component read callback. The read value of * the respective Device u32 component should be passed * back via the val parameter. -* @count_u32_read: Count u32 component read callback. The read value of the +* @count_u32_read: Count u32 component read callback. The read value of the * respective Count u32 component should be passed back via * the val parameter. -* @signal_u32_read: Signal u32 component read callback. The read value of +* @signal_u32_read: Signal u32 component read callback. The read value of * the respective Signal u32 component should be passed * back via the val parameter. -* @device_u64_read: Device u64 component read callback. The read value of +* @device_u64_read: Device u64 component read callback. The read value of * the respective Device u64 component should be passed * back via the val parameter. -* @count_u64_read: Count u64 component read callback. The read value of the +* @count_u64_read: Count u64 component read callback. The read value of the * respective Count u64 component should be passed back via * the val parameter. -* @signal_u64_read: Signal u64 component read callback. The read value of +* @signal_u64_read: Signal u64 component read callback. The read value of * the respective Signal u64 component should be passed * back via the val parameter. -* @action_write: Synapse action mode write callback. The write value of +* @action_write: Synapse action mode write callback. The write value of * the respective Synapse action mode is passed via the * action parameter. -* @device_u8_write: Device u8 component write callback. The write value of +* @device_u8_write: Device u8 component write callback. The write value of * the respective Device u8 component is passed via the val * parameter. -* @count_u8_write: Count u8 component write callback. The write value of +* @count_u8_write: Count u8 component write callback. The write value of * the respective Count u8 component is passed via the val * parameter. -* @signal_u8_write: Signal u8 component write callback. The write value of +* @signal_u8_write: Signal u8 component write callback. The write value of * the respective Signal u8 component is passed via the val * parameter. -* @device_u32_write: Device u32 component write callback. The write value of +* @device_u32_write: Device u32 component write callback. The write value of * the respective Device u32 component is passed via the * val parameter. -* @count_u32_write: Count u32 component write callback. The write value of +* @count_u32_write: Count u32 component write callback. The write value of * the respective Count u32 component is passed via the val * parameter. -* @signal_u32_write: Signal u32 component write callback. The write value of +* @signal_u32_write: Signal u32 component write callback. The write value of * the respective Signal u32 component is passed via the * val parameter. -* @device_u64_write: Device u64 component write callback. The write value of +* @device_u64_write: Device u64 component write callback. The write value of * the respective Device u64 component is passed via the * val parameter. -* @count_u64_write: Count u64 component write callback. The write value of +* @count_u64_write: Count u64 component write callback. The write value of * the respective Count u64 component is passed via the val * parameter. -* @signal_u64_write: Signal u64 component write callback. The write value of +* @signal_u64_write: Signal u64 component write callback. The write value of * the respective Signal u64 component is passed via the * val parameter. */
Signature · 1 line
2.37.3
Re: [PATCH 2/2] counter: Realign counter_comp comment block to 80 characters
Quoted 11 lines · William Breathitt Gray
The member documentation comment lines for struct
counter_compextend past the 80-characters column boundary due to extra identation at the start of each section. This patch realigns the comment block within the 80-characters boundary by removing these superfluous indents.Reviewed-by Yanteng Si <[email protected]>Signed-off-by William Breathitt Gray <[email protected]>--- include/linux/counter.h | 40 ++++++++++++++++++++-------------------- 1 file changed, 20 insertions(+), 20 deletions(-)
This isn't needed for 6.0-final, I'll queue it up in my -next branch for 6.1-rc1.
thanks,
greg k-h