Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 27 Apr 2013 12:44:29 -0700
From:      Justin Hibbits <jrh29@alumni.cwru.edu>
To:        FreeBSD PowerPC ML <freebsd-ppc@freebsd.org>
Subject:   ppc64 kernel dumps
Message-ID:  <CAHSQbTCyDGL62wQ=K52gZjkf_MofZOSM9kNMT94wqrfh0oyVeQ@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
--bcaec51ba00f469f9e04db5ce13e
Content-Type: text/plain; charset=ISO-8859-1

Attached is my work on ppc64 kernel dumps, based on my ppc32 dump code
(stolen from booke).  There is one problem that I see, but I can't figure
out how to solve, which is that on my machine at least, after some number
of chunks dumped, the ATA transfer times out, failing the dump.  I think it
wedges the DMA controller, but I'm not certain.  Maybe Nathan, or someone
else, can shed some light on it.

- Justin

--bcaec51ba00f469f9e04db5ce13e
Content-Type: application/octet-stream; name="dump_oea64.diff"
Content-Disposition: attachment; filename="dump_oea64.diff"
Content-Transfer-Encoding: base64
X-Attachment-Id: f_hg176bzy0

SW5kZXg6IGFpbS9tbXVfb2VhNjQuYwo9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09
PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09Ci0tLSBhaW0vbW11X29lYTY0LmMJKHJl
dmlzaW9uIDI0OTc0NSkKKysrIGFpbS9tbXVfb2VhNjQuYwkod29ya2luZyBjb3B5KQpAQCAtMTky
LDYgKzE5MiwxMSBAQAogCWNlbGxfdAlvbV9tb2RlOwogfTsKIAorZXh0ZXJuIHVuc2lnbmVkIGNo
YXIgX2V0ZXh0W107CitleHRlcm4gdW5zaWduZWQgY2hhciBfZW5kW107CisKK2V4dGVybiBpbnQg
ZHVtcHN5c19taW5pZHVtcDsKKwogLyoKICAqIE1hcCBvZiBwaHlzaWNhbCBtZW1vcnkgcmVnaW9u
cy4KICAqLwpAQCAtMzMwLDYgKzMzNSw5IEBACiB2b2lkIG1vZWE2NF9rZW50ZXIobW11X3QsIHZt
X29mZnN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1kLm1kX3BhZGRyID0gcHJlZ2lvbnNbbWQubWRfaW5k
ZXhdLm1yX3N0YXJ0OworCQkJbWQubWRfc2l6ZSA9IHByZWdpb25zW21kLm1kX2luZGV4XS5tcl9z
aXplOworCQkJbWQubWRfdmFkZHIgPSB+MFVMOworCQkJbWQubWRfaW5kZXgrKzsKKwkJfSBlbHNl
IHsKKwkJCS8qIFRoZXJlJ3Mgbm8gbmV4dCBwaHlzaWNhbCBjaHVuay4gKi8KKwkJCXJldHVybiAo
TlVMTCk7CisJCX0KKwl9CisKKwlyZXR1cm4gKCZtZCk7Cit9Cg==
--bcaec51ba00f469f9e04db5ce13e--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAHSQbTCyDGL62wQ=K52gZjkf_MofZOSM9kNMT94wqrfh0oyVeQ>