ccgx: Do no show the flash parameters when unknown

This commit is contained in:
Richard Hughes 2020-04-16 09:51:00 +01:00
parent 35ca4cbc61
commit 54e3feae12

View File

@ -64,7 +64,9 @@ fu_ccgx_hpi_device_to_string (FuDevice *device, guint idt, GString *str)
fu_common_string_append_kx (str, idt, "EpBulkIn", self->ep_bulk_in); fu_common_string_append_kx (str, idt, "EpBulkIn", self->ep_bulk_in);
fu_common_string_append_kx (str, idt, "EpBulkOut", self->ep_bulk_out); fu_common_string_append_kx (str, idt, "EpBulkOut", self->ep_bulk_out);
fu_common_string_append_kx (str, idt, "EpIntrIn", self->ep_intr_in); fu_common_string_append_kx (str, idt, "EpIntrIn", self->ep_intr_in);
if (self->flash_row_size > 0)
fu_common_string_append_kx (str, idt, "FlashRowSize", self->flash_row_size); fu_common_string_append_kx (str, idt, "FlashRowSize", self->flash_row_size);
if (self->flash_size > 0)
fu_common_string_append_kx (str, idt, "FlashSize", self->flash_size); fu_common_string_append_kx (str, idt, "FlashSize", self->flash_size);
} }