[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen master] xen/arm: domain_build: harden make_cpus_node()
*** New tip has no discernable common ancestor with previous history *** Previously reported histories end at: e01fa4e223fc077e18936d890dbd4813c3e7c9b1 3a28f760508fb35c430edac17a9efde5aff6d1d5 123c7793797502b222300eb710cd3873dcca41ee c40317f11b3f05e7c06a2213560c8471081f2662 a6f2cdb633bf519244a16674031b8034b581ba7f 8e4b2676685f50bc26f03b5f62d8b7aea8e69dbf 2f5af2c962c05b789bdd65b46c74711e903f86d0 695bb5f504ab48c1d546446f104c1b6c0ead126d 9053a74c08fd6abf43bb45ff932b4386de7e8510 16b1414de91b5a82a0996c67f6db3af7d7e32873 572a78190403e5f2acbd01fa72c35fafe9700169 e871e80c38547d9faefc6604532ba3e985e65873 a823a5280f25ad19a751dd9a41044f556471e61a 6d8ffac1f7a782dc2c7f8df3871a294729ae36bd cb70a26f78848fe45f593f7ebc9cfaac760a791b e83077a3d11072708a5c38fa09fa9d011914e2a1 6c9639a72f0ca3a9430ef75f375877182281fdef 1014f47c7a808e025b8920ab80bfe73a2888b3e5 f93abf0315efef861270c25d83c8047fd6a54ec4 commit fef8d99fbce1a5e7ddfd22b0f33940b8d6193ec8 Author: Stefano Stabellini <sstabellini@xxxxxxxxxx> AuthorDate: Wed Oct 9 17:42:11 2019 -0700 Commit: Stefano Stabellini <sstabellini@xxxxxxxxxx> CommitDate: Thu Oct 10 11:17:08 2019 -0700 xen/arm: domain_build: harden make_cpus_node() make_cpus_node() is using a static buffer to generate the FDT node name. While mpdir_aff is a 64-bit integer, we only ever use the bits [23:0] as only AFF{0, 1, 2} are supported for now. To avoid any potential issues in the future, check that mpdir_aff has only bits [23:0] set. Take the opportunity to reduce the size of the buffer. Indeed, only 8 characters are needed to print a 32-bit hexadecimal number. So sizeof("cpu@") + 8 + 1 (for '\0') = 13 characters is sufficient. Fixes: c81a791d34 (xen/arm: Set 'reg' of cpu node for dom0 to match MPIDR's affinity) Signed-off-by: Stefano Stabellini <stefano.stabellini@xxxxxxxxxx> Reviewed-by: Julien Grall <julien.grall@xxxxxxx> Release-acked-by: Juergen Gross <jgross@xxxxxxxx> -- generated by git-patchbot for /home/xen/git/xen.git#master _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |