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

x/sys/cpu: cpu_linux.go:31 /proc/self/auxv: permission denied on android/arm #30413

Closed
rayvbr opened this issue Feb 26, 2019 · 4 comments
Closed
Labels
FrozenDueToAge NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. OS-Android
Milestone

Comments

@rayvbr
Copy link

rayvbr commented Feb 26, 2019

What version of Go are you using (go version)?

Go 1.12

Does this issue reproduce with the latest release?

Yes

What operating system and processor architecture are you using (go env)?

Using 'gomobile bind' to compile to android/arm

What did you do?

Compile arbitrary library (hello world) to android/arm using 'gomobile bind' (Android NDK 19b). Include in Android Java app.

Note: used git head of golang.org/x/sys (golang/sys@cc5685c)

What did you expect to see?

Running application

What did you see instead?

2019-02-26 19:12:32.502 8053-0/? E/Go: panic: read proc auxv failed: open /proc/self/auxv: permission denied
2019-02-26 19:12:32.502 8053-8094/? E/GoLog: panic: read proc auxv failed: open /proc/self/auxv: permission denied
2019-02-26 19:12:32.502 8053-0/? E/Go: goroutine 1 [running]:
2019-02-26 19:12:32.502 8053-0/? E/Go: <redacted>vendor/golang.org/x/sys/cpu.init.0()
2019-02-26 19:12:32.502 8053-0/? E/Go: 	<redacted>/vendor/golang.org/x/sys/cpu/cpu_linux.go:31 +0x1ac
2019-02-26 19:12:32.503 8053-8090/? E/CRASH: signal 6 (SIGABRT), code -6 (?), fault addr --------
2019-02-26 19:12:32.503 8053-8090/? E/CRASH: *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
@gopherbot gopherbot added this to the Unreleased milestone Feb 26, 2019
@rayvbr
Copy link
Author

rayvbr commented Feb 26, 2019

Go 1.11.4 with golang.org/x/sys golang/sys@4d1cda0 works fine

@rayvbr
Copy link
Author

rayvbr commented Feb 26, 2019

Possibly related to #9229

Note that not all chipsets seem affected. Crash above was on Snapdragon 821. Exynos 8890 seems unaffected

@tklauser tklauser added OS-Android NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. labels Feb 27, 2019
@gopherbot
Copy link

Change https://golang.org/cl/164057 mentions this issue: cpu: don't panic on error reading /proc/self/auxv

@rayvbr
Copy link
Author

rayvbr commented Feb 28, 2019

Problem resolved! Thanks guys!

@golang golang locked and limited conversation to collaborators Feb 28, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
FrozenDueToAge NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. OS-Android
Projects
None yet
Development

No branches or pull requests

3 participants