* [PATCH] powerpc/ucc_geth: deal with an compile warning
@ 2014-06-24 8:18 Zhao Qiang
2014-06-24 18:04 ` Scott Wood
0 siblings, 1 reply; 2+ messages in thread
From: Zhao Qiang @ 2014-06-24 8:18 UTC (permalink / raw)
To: linuxppc-dev, B07421; +Cc: Zhao Qiang
deal with a compile warning: comparison between
'enum qe_fltr_largest_external_tbl_lookup_key_size'
and 'enum qe_fltr_tbl_lookup_key_size'
the code:
"if (ug_info->largestexternallookupkeysize ==
QE_FLTR_TABLE_LOOKUP_KEY_SIZE_8_BYTES)"
is warned because different enum, so modify it.
"enum qe_fltr_largest_external_tbl_lookup_key_size
largestexternallookupkeysize;
enum qe_fltr_tbl_lookup_key_size {
QE_FLTR_TABLE_LOOKUP_KEY_SIZE_8_BYTES
= 0x3f, /* LookupKey parsed by the Generate LookupKey
CMD is truncated to 8 bytes */
QE_FLTR_TABLE_LOOKUP_KEY_SIZE_16_BYTES
= 0x5f, /* LookupKey parsed by the Generate LookupKey
CMD is truncated to 16 bytes */
};
/* QE FLTR extended filtering Largest External Table Lookup Key Size */
enum qe_fltr_largest_external_tbl_lookup_key_size {
QE_FLTR_LARGEST_EXTERNAL_TABLE_LOOKUP_KEY_SIZE_NONE
= 0x0,/* not used */
QE_FLTR_LARGEST_EXTERNAL_TABLE_LOOKUP_KEY_SIZE_8_BYTES
= QE_FLTR_TABLE_LOOKUP_KEY_SIZE_8_BYTES, /* 8 bytes */
QE_FLTR_LARGEST_EXTERNAL_TABLE_LOOKUP_KEY_SIZE_16_BYTES
= QE_FLTR_TABLE_LOOKUP_KEY_SIZE_16_BYTES, /* 16 bytes */
};"
Signed-off-by: Zhao Qiang <B45475@freescale.com>
---
drivers/net/ethernet/freescale/ucc_geth.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/net/ethernet/freescale/ucc_geth.c b/drivers/net/ethernet/freescale/ucc_geth.c
index ee2f1ff..0b0de89 100644
--- a/drivers/net/ethernet/freescale/ucc_geth.c
+++ b/drivers/net/ethernet/freescale/ucc_geth.c
@@ -2993,11 +2993,11 @@ static int ucc_geth_startup(struct ucc_geth_private *ugeth)
if (ug_info->rxExtendedFiltering) {
size += THREAD_RX_PRAM_ADDITIONAL_FOR_EXTENDED_FILTERING;
if (ug_info->largestexternallookupkeysize ==
- QE_FLTR_TABLE_LOOKUP_KEY_SIZE_8_BYTES)
+ QE_FLTR_LARGEST_EXTERNAL_TABLE_LOOKUP_KEY_SIZE_8_BYTES)
size +=
THREAD_RX_PRAM_ADDITIONAL_FOR_EXTENDED_FILTERING_8;
if (ug_info->largestexternallookupkeysize ==
- QE_FLTR_TABLE_LOOKUP_KEY_SIZE_16_BYTES)
+ QE_FLTR_LARGEST_EXTERNAL_TABLE_LOOKUP_KEY_SIZE_16_BYTES)
size +=
THREAD_RX_PRAM_ADDITIONAL_FOR_EXTENDED_FILTERING_16;
}
--
1.8.5
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] powerpc/ucc_geth: deal with an compile warning
2014-06-24 8:18 [PATCH] powerpc/ucc_geth: deal with an compile warning Zhao Qiang
@ 2014-06-24 18:04 ` Scott Wood
0 siblings, 0 replies; 2+ messages in thread
From: Scott Wood @ 2014-06-24 18:04 UTC (permalink / raw)
To: Zhao Qiang; +Cc: B07421, linuxppc-dev
On Tue, 2014-06-24 at 16:18 +0800, Zhao Qiang wrote:
> deal with a compile warning: comparison between
> 'enum qe_fltr_largest_external_tbl_lookup_key_size'
> and 'enum qe_fltr_tbl_lookup_key_size'
>
> the code:
> "if (ug_info->largestexternallookupkeysize ==
> QE_FLTR_TABLE_LOOKUP_KEY_SIZE_8_BYTES)"
> is warned because different enum, so modify it.
>
> "enum qe_fltr_largest_external_tbl_lookup_key_size
> largestexternallookupkeysize;
>
> enum qe_fltr_tbl_lookup_key_size {
> QE_FLTR_TABLE_LOOKUP_KEY_SIZE_8_BYTES
> = 0x3f, /* LookupKey parsed by the Generate LookupKey
> CMD is truncated to 8 bytes */
> QE_FLTR_TABLE_LOOKUP_KEY_SIZE_16_BYTES
> = 0x5f, /* LookupKey parsed by the Generate LookupKey
> CMD is truncated to 16 bytes */
> };
>
> /* QE FLTR extended filtering Largest External Table Lookup Key Size */
> enum qe_fltr_largest_external_tbl_lookup_key_size {
> QE_FLTR_LARGEST_EXTERNAL_TABLE_LOOKUP_KEY_SIZE_NONE
> = 0x0,/* not used */
> QE_FLTR_LARGEST_EXTERNAL_TABLE_LOOKUP_KEY_SIZE_8_BYTES
> = QE_FLTR_TABLE_LOOKUP_KEY_SIZE_8_BYTES, /* 8 bytes */
> QE_FLTR_LARGEST_EXTERNAL_TABLE_LOOKUP_KEY_SIZE_16_BYTES
> = QE_FLTR_TABLE_LOOKUP_KEY_SIZE_16_BYTES, /* 16 bytes */
> };"
>
> Signed-off-by: Zhao Qiang <B45475@freescale.com>
> ---
> drivers/net/ethernet/freescale/ucc_geth.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
This needs to be sent to the netdev list and maintainer.
-Scott
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-06-30 23:27 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-06-24 8:18 [PATCH] powerpc/ucc_geth: deal with an compile warning Zhao Qiang
2014-06-24 18:04 ` Scott Wood
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).