All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
To: unlisted-recipients:; (no To-header on input)
Cc: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>,
	"Daniel W. S. Almeida" <dwlsalmeida@gmail.com>,
	Mauro Carvalho Chehab <mchehab@kernel.org>,
	linux-kernel@vger.kernel.org, linux-media@vger.kernel.org
Subject: [PATCH RFC 07/11] media: vidtv: remove a wrong endiannes check from s302m generator
Date: Mon, 14 Sep 2020 11:03:22 +0200	[thread overview]
Message-ID: <23a923f8ff24fe06565c4720572bef16b82ef03d.1600073975.git.mchehab+huawei@kernel.org> (raw)
In-Reply-To: <cover.1600073975.git.mchehab+huawei@kernel.org>

The code there is already doing the right thing, as it uses
value & 0xff, value & 0xff00, which already ensures the
expected endiannes.

So, it doesn't make any sense to touch the order depending on
the CPU endiannes.

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
---
 drivers/media/test-drivers/vidtv/vidtv_s302m.c | 8 --------
 1 file changed, 8 deletions(-)

diff --git a/drivers/media/test-drivers/vidtv/vidtv_s302m.c b/drivers/media/test-drivers/vidtv/vidtv_s302m.c
index 5ae2ede951eb..1bab2e231a55 100644
--- a/drivers/media/test-drivers/vidtv/vidtv_s302m.c
+++ b/drivers/media/test-drivers/vidtv/vidtv_s302m.c
@@ -352,14 +352,6 @@ static u32 vidtv_s302m_write_frame(struct vidtv_encoder *e,
 	f.data[3] = (sample & 0x0FF0) >>  4;
 	f.data[4] = (sample & 0xF000) >> 12;
 
-	#ifdef __LITTLE_ENDIAN
-	f.data[0] = reverse[f.data[0]];
-	f.data[1] = reverse[f.data[1]];
-	f.data[2] = reverse[f.data[2]];
-	f.data[3] = reverse[f.data[3]];
-	f.data[4] = reverse[f.data[4]];
-	#endif
-
 	nbytes += vidtv_memcpy(e->encoder_buf,
 			       e->encoder_buf_offset,
 			       VIDTV_S302M_BUF_SZ,
-- 
2.26.2


  parent reply	other threads:[~2020-09-14  9:04 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-14  9:03 [PATCH RFC 00/11] Solve some issues and do some improvements at vidtv Mauro Carvalho Chehab
2020-09-14  9:03 ` [PATCH RFC 01/11] media: vidtv: add modaliases for the bridge driver Mauro Carvalho Chehab
2020-09-14  9:03 ` [PATCH RFC 02/11] media: vidtv: prefer using dev_foo() instead of pr_foo() Mauro Carvalho Chehab
2020-09-14  9:03 ` [PATCH RFC 03/11] media: vidtv: fix 32-bit warnings Mauro Carvalho Chehab
2020-09-14  9:03 ` [PATCH RFC 04/11] media: vidtv: fix frequency tuning logic Mauro Carvalho Chehab
2020-09-14  9:03 ` [PATCH RFC 05/11] media: vidtv: add an initial channel frequency Mauro Carvalho Chehab
2020-09-14  9:03 ` [PATCH RFC 06/11] media: vidtv: get rid of some endiannes nonsense Mauro Carvalho Chehab
2020-09-14 15:14   ` Daniel W. S. Almeida
2020-09-15 11:49     ` Mauro Carvalho Chehab
2020-09-14  9:03 ` Mauro Carvalho Chehab [this message]
2020-09-16 18:13   ` [PATCH RFC 07/11] media: vidtv: remove a wrong endiannes check from s302m generator kernel test robot
2020-09-16 18:13     ` kernel test robot
2020-09-14  9:03 ` [PATCH RFC 08/11] media: vidtv: properly initialize the internal state struct Mauro Carvalho Chehab
2020-09-14  9:03 ` [PATCH RFC 09/11] media: vidtv: add basic support for DVBv5 stats Mauro Carvalho Chehab
2020-09-14  9:03 ` [PATCH RFC 10/11] media: vidtv: get rid of the work queue Mauro Carvalho Chehab
2020-09-14  9:03 ` [PATCH RFC 11/11] media: vidtv: increment byte and block counters Mauro Carvalho Chehab

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=23a923f8ff24fe06565c4720572bef16b82ef03d.1600073975.git.mchehab+huawei@kernel.org \
    --to=mchehab+huawei@kernel.org \
    --cc=dwlsalmeida@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=mchehab@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.