Skip to content
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion drivers/soc/atmel/soc.c
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,12 @@ static const struct at91_soc __initconst socs[] = {
#endif
#ifdef CONFIG_SOC_SAM9X60
AT91_SOC(SAM9X60_CIDR_MATCH, SAM9X60_EXID_MATCH, "sam9x60", "sam9x60"),
AT91_SOC(SAM9X60_CIDR_MATCH, SAM9X60D5M_EXID_MATCH,

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd like that the #defines are like the other ones: SAM9X60_D5M_EXID_MATCH

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@noglitch : EXID_MATCH definitions changed with commit feff97a.

"sam9x60d6m", "sam9x60"),

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Take example on sama5d2 SiP lines to have a coherent display between the different SiP products.

AT91_SOC(SAM9X60_CIDR_MATCH, SAM9X60D1G_EXID_MATCH,
"sam9x60d1g", "sam9x60"),
AT91_SOC(SAM9X60_CIDR_MATCH, SAM9X60D6K_EXID_MATCH,
"sam9x60d6k", "sam9x60"),
#endif
#ifdef CONFIG_SOC_SAMA5
AT91_SOC(SAMA5D2_CIDR_MATCH, SAMA5D21CU_EXID_MATCH,
Expand Down Expand Up @@ -237,7 +243,8 @@ struct soc_device * __init at91_soc_init(const struct at91_soc *socs)
}

if (!soc->name) {
pr_warn("Could not find matching SoC description\n");
pr_warn("Could not find matching SoC description"
" (cidr %08x, exid %08x)", cidr, exid);
return NULL;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is an unrelated change

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should I revert the change of the warning and probably create a different pull request? It is definitely useful, when running on yet unsupported soc's.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, two separate patches would be the best. However, This will increase the kernel size for a very unusual use case. Most of the time, the soc ids will be present. Maybe use pr_debug ?

BTW, are you actually using this driver for something useful?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I reverted the change of the print and decided not to create a different pull request for it. As You pointed out, it should be of rare use. To be honest, I don't know, what the soc registration is good for. I just stumbled over the ""Could not find matching SoC description" warning in the dmesg and fixed it.

You proposed to submit this change upstream. I guess You mean submitting it to the mainline kernel. I requested the pull to linux-at91, because this is my direct upstream. And I thought, that the linux-at91 maintainers will submit relevant changes further up.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, we can do it.

}

Expand Down
3 changes: 3 additions & 0 deletions drivers/soc/atmel/soc.h
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,9 @@ at91_soc_init(const struct at91_soc *socs);
#define AT91SAM9CN11_EXID_MATCH 0x00000009

#define SAM9X60_EXID_MATCH 0x00000000
#define SAM9X60D5M_EXID_MATCH 0x00000001
#define SAM9X60D1G_EXID_MATCH 0x00000010
#define SAM9X60D6K_EXID_MATCH 0x00000011

#define AT91SAM9XE128_CIDR_MATCH 0x329973a0
#define AT91SAM9XE256_CIDR_MATCH 0x329a93a0
Expand Down