Linux kernel -stable discussions
 help / color / mirror / Atom feed
* [PATCH] media: cec: core: remove length check of Timer Status solution applies to 5.4 and 4.19
@ 2024-04-12 10:14 Nini Song (宋宛妮)
  2024-04-14 13:41 ` Greg KH
  0 siblings, 1 reply; 2+ messages in thread
From: Nini Song (宋宛妮) @ 2024-04-12 10:14 UTC (permalink / raw)
  To: stable@vger.kernel.org; +Cc: linux-mediatek@lists.infradead.org


[-- Attachment #1.1.1: Type: text/plain, Size: 379 bytes --]

Hi @stable@vger.kernel.org<mailto:stable@vger.kernel.org>

This patch has been merged in mainline as commit ce5d241c3ad45.
[patch diff]
[cid:image001.png@01DA8D04.BCD8A070]

Because of our customer used v5.15, v5.4 and 4.19 for MP production, which requires this solution.

We need your help apply the patch in v5.15, v5.4 and 4.19.



Thanks!

BR,

Nini Song


[-- Attachment #1.1.2: Type: text/html, Size: 3750 bytes --]

[-- Attachment #1.2: image001.png --]
[-- Type: image/png, Size: 39807 bytes --]

[-- Attachment #2: Type: message/rfc822, Size: 17737 bytes --]

[-- Attachment #2.1.1: Type: text/plain, Size: 2435 bytes --]

External email : Please do not click links or open attachments until you have verified the sender or the content.


Hi Nini,

This patch has now been merged in mainline as commit ce5d241c3ad45
("media: cec: core: remove length check of Timer Status").

To get this into older kernels please post this patch to
stable@vger.kernel.org, CC the linux-media mailinglist, and mention the
mainline commit that I provided above.

Also mention that this patch applies to 5.10 and up. You can mention
that the patch applies to 5.4 and 4.19 as well after removing the '/core'
directory from the pathnames.

Since you are the author of the patch, you should be the one to post
the patch.

Regards,

Hans


On 25/01/2024 14:28, nini.song@mediatek.com wrote:
> From: "nini.song" <nini.song@mediatek.com>
>
> The valid_la is used to check the length requirements,
> including special cases of Timer Status. If the length is
> shorter than 5, that means no Duration Available is returned,
> the message will be forced to be invalid.
>
> However, the description of Duration Available in the spec
> is that this parameter may be returned when these cases, or
> that it can be optionally return when these cases. The key
> words in the spec description are flexible choices.
>
> Remove the special length check of Timer Status to fit the
> spec which is not compulsory about that.
>
> Signed-off-by: Nini Song <nini.song@mediatek.com>
> ---
>  drivers/media/cec/core/cec-adap.c | 14 --------------
>  1 file changed, 14 deletions(-)
>
> diff --git a/drivers/media/cec/core/cec-adap.c b/drivers/media/cec/core/cec-adap.c
> index 5741adf09a2e..559a172ebc6c 100644
> --- a/drivers/media/cec/core/cec-adap.c
> +++ b/drivers/media/cec/core/cec-adap.c
> @@ -1151,20 +1151,6 @@ void cec_received_msg_ts(struct cec_adapter *adap,
>  if (valid_la && min_len) {
>  /* These messages have special length requirements */
>  switch (cmd) {
> -case CEC_MSG_TIMER_STATUS:
> -if (msg->msg[2] & 0x10) {
> -switch (msg->msg[2] & 0xf) {
> -case CEC_OP_PROG_INFO_NOT_ENOUGH_SPACE:
> -case CEC_OP_PROG_INFO_MIGHT_NOT_BE_ENOUGH_SPACE:
> -if (msg->len < 5)
> -valid_la = false;
> -break;
> -}
> -} else if ((msg->msg[2] & 0xf) == CEC_OP_PROG_ERROR_DUPLICATE) {
> -if (msg->len < 5)
> -valid_la = false;
> -}
> -break;
>  case CEC_MSG_RECORD_ON:
>  switch (msg->msg[2]) {
>  case CEC_OP_RECORD_SRC_OWN:



[-- Attachment #2.1.2: Type: text/html, Size: 3558 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] media: cec: core: remove length check of Timer Status solution applies to 5.4 and 4.19
  2024-04-12 10:14 [PATCH] media: cec: core: remove length check of Timer Status solution applies to 5.4 and 4.19 Nini Song (宋宛妮)
@ 2024-04-14 13:41 ` Greg KH
  0 siblings, 0 replies; 2+ messages in thread
From: Greg KH @ 2024-04-14 13:41 UTC (permalink / raw)
  To: Nini Song (宋宛妮)
  Cc: stable@vger.kernel.org, linux-mediatek@lists.infradead.org

On Fri, Apr 12, 2024 at 10:14:41AM +0000, Nini Song (宋宛妮) wrote:
> Hi @stable@vger.kernel.org<mailto:stable@vger.kernel.org>
> 
> This patch has been merged in mainline as commit ce5d241c3ad45.
> [patch diff]
> [cid:image001.png@01DA8D04.BCD8A070]
> 
> Because of our customer used v5.15, v5.4 and 4.19 for MP production, which requires this solution.
> 
> We need your help apply the patch in v5.15, v5.4 and 4.19.

It does not apply to 5.4.y or 4.19.y, can you please provide a working
and tested backported patch so that we can add it there?  I have now
added it to all other branches.

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2024-04-14 13:41 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-04-12 10:14 [PATCH] media: cec: core: remove length check of Timer Status solution applies to 5.4 and 4.19 Nini Song (宋宛妮)
2024-04-14 13:41 ` Greg KH

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox