Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build/tools/amebasmart: Modify Flash Protection Status Register #6111

Merged
merged 1 commit into from
Mar 22, 2024

Conversation

ZhenBei-Sin
Copy link
Contributor

Changes Note:
Modify the Flash Protection Status Register from 0x2C to 0x28 To protect 512KB of flash

@sunghan-chang
Copy link
Contributor

sunghan-chang commented Mar 22, 2024

@ZhenBei-Sin Why is this happened? There was no requirement change on this ever.

jeongarmy
jeongarmy previously approved these changes Mar 22, 2024
Copy link
Contributor

@jeongarmy jeongarmy left a comment

Choose a reason for hiding this comment

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

LGTM

@sunghan-chang
Copy link
Contributor

@ZhenBei-Sin Please update the secure storage test example to verify this. I mean that the app should test range of write protection.

@sunghan-chang
Copy link
Contributor

@ZhenBei-Sin Please update the secure storage test example to verify this. I mean that the app should test range of write protection.

Let's do this with new PR, not in this PR.

Comment on lines 36 to 45
/* Flash Status Bit Protect Lower 512KB */
#ifdef CONFIG_AMEBAD_TRUSTZONE
#define FLASH_STATUS_BITS 0x2c
#endif
#ifdef CONFIG_AMEBASMART_TRUSTZONE
#define FLASH_STATUS_BITS 0x28
#endif
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't know this is proper. I don't have any requirement change on this. But anyway, when we want to change the region, we should modify several files. And it could be mismatched.
How about making this as a config?

And here are amebad and amebasmart only. How about amebalite? Because we support it, I ask you this.

Copy link
Contributor

Choose a reason for hiding this comment

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

Different IC packaging uses different Flash, it has different Status bits values.
We will base it on previous AmebaLite packaging, thus it's the same as AmebaD.

We will create another PR to change this setting to a config, is that okay?

Copy link
Contributor

Choose a reason for hiding this comment

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

Different IC packaging uses different Flash, it has different Status bits values.
We will base it on previous AmebaLite packaging, thus it's the same as AmebaD.

Because of that, I suggest making a config to set for different boards configuration.

We will create another PR to change this setting to a config, is that okay?

Sure

Changes Note:
Modify the Flash Protection Status Register from 0x2C to 0x28
To protect 512KB of flash
Copy link
Contributor

@sunghan-chang sunghan-chang left a comment

Choose a reason for hiding this comment

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

@ZhenBei-Sin @ziyik Can I merge this now?

@ZhenBei-Sin
Copy link
Contributor Author

@ZhenBei-Sin @ziyik Can I merge this now?

Yes~ please proceed to merge. Thank you ~

@sunghan-chang sunghan-chang merged commit 793f8d9 into Samsung:master Mar 22, 2024
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants