Closed
Bug 782124
Opened 12 years ago
Closed 9 years ago
Implement PR_GetPhysicalMemorySize on FreeBSD
Categories
(NSPR :: NSPR, defect, P1)
Tracking
(Not tracked)
RESOLVED
FIXED
4.10.8
People
(Reporter: jbeich, Assigned: jbeich)
References
(Blocks 1 open bug, )
Details
Attachments
(1 file, 2 obsolete files)
1.72 KB,
patch
|
wtc
:
review+
wtc
:
checked-in+
|
Details | Diff | Splinter Review |
No description provided.
Attachment #651202 -
Flags: review?(wtc)
Now it should work on 32bit systems. Sorry.
Attachment #651202 -
Attachment is obsolete: true
Attachment #651202 -
Flags: review?(wtc)
Attachment #651203 -
Flags: review?(wtc)
Keep extra ifdef simple in case more BSD forks are added or FreeBSD/DragonFly grow support for hw.physmem64: #ifdef HW_PHYSMEM64
Attachment #651203 -
Attachment is obsolete: true
Attachment #651203 -
Flags: review?(wtc)
Attachment #652733 -
Flags: review?(wtc)
Updated•10 years ago
|
Status: UNCONFIRMED → NEW
Ever confirmed: true
Hardware: x86_64 → All
Comment 4•10 years ago
|
||
Lacking this support is starting to seriously hurt us on FreeBSD now that we are using PR_GetPhysicalMemorySize more. Can we move forward on getting a review for this?
Flags: needinfo?(wtc)
Comment on attachment 652733 [details] [diff] [review] reuse code for other BSDs, v3 typo check: https://treeherder.mozilla.org/ui/#/jobs?repo=try&revision=f48f6aff3ee5 Also tested within FreeBSD ports and DragonFly DPorts. https://svnweb.freebsd.org/ports/head/devel/nspr/files/patch-bug782124?view=markup https://github.com/DragonFlyBSD/DPorts/blob/master/devel/nspr/files/patch-bug782124
Comment 6•9 years ago
|
||
Comment on attachment 652733 [details] [diff] [review] reuse code for other BSDs, v3 Review of attachment 652733 [details] [diff] [review]: ----------------------------------------------------------------- r=wtc. Thanks for the patch. Patch checked in on the NSPR trunk: https://hg.mozilla.org/projects/nspr/rev/1ec32b5680f7 ::: nsprpub/pr/src/misc/prsystem.c @@ +300,3 @@ > uint64_t memSize; > +#else > + unsigned long memSize; I found some sample code on the Web that declares this variable as unsigned int. Which type is correct?
Attachment #652733 -
Flags: review?(wtc)
Attachment #652733 -
Flags: review+
Attachment #652733 -
Flags: checked-in+
Comment 7•9 years ago
|
||
This fix will be in the upcoming NSPR 4.10.8 release.
Assignee: wtc → jbeich
Status: NEW → RESOLVED
Closed: 9 years ago
Flags: needinfo?(wtc)
Priority: -- → P1
Resolution: --- → FIXED
Target Milestone: --- → 4.10.8
(In reply to Wan-Teh Chang from comment #6) > ::: nsprpub/pr/src/misc/prsystem.c > @@ +300,3 @@ > > uint64_t memSize; > > +#else > > + unsigned long memSize; > > I found some sample code on the Web that declares this variable as > unsigned int. Which type is correct? There's no correct type for HW_PHYSMEM. It was originally |int| on 4.4BSD and still is on OpenBSD. FreeBSD casted off signedness and changed to long. https://github.com/freebsd/freebsd/commit/c7c00ab (ca. FreeBSD 4.5) https://github.com/freebsd/freebsd/commit/c3bdd66 (ca. FreeBSD 5.0) NetBSD casted off signedness and added HW_PHYSMEM64. https://github.com/jsonn/src/commit/35da98c OpenBSD adapted HW_PHYSMEM64. http://anoncvs.estpak.ee/cgi-bin/cgit/openbsd-src/commit/?id=c2e18ba DragonFly inherited unsigned from FreeBSD 4.8 and later adapted long. http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/39d69da
You need to log in
before you can comment on or make changes to this bug.
Description
•