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tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0oIDkpIERhdGEgNQorRGF0YSA2ICggOCktLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0oMTApIERhdGEgNgorRGF0YSA3ICggOSktLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0oMTEpIERhdGEgNworICAgICAgICgxMCkgICAgICAgICAgICAgICAgICAgICAgWys1dl0tLS0oIDEpIFZkZAorICAgICAgICgxMSkgICAgICAgICAgICAgICAgICAgICAgW0dORF0tLS0oIDIpIEdyb3VuZAorICAgICAgICgxMikgICAgICAgICAgICAgICAgICAgICAgWys1dl0tLS0oMTQpIFJlc2V0CisgICAgICAgKDEzKSAgICAgICAgICAgICAgICAgICAgICBbR05EXS0tLSgxNSkgUmVhZCAvIFdyaXRlCisgIExpbmUgKDE0KS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLSgxMykgQ29udHJvbGxlciBTZWxlY3QgMQorICAgICAgICgxNSkKKyAgSW5pdCAoMTYpLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tKDEyKSBDb250cm9sbGVyIFNlbGVjdCAyCitTZWxlY3QgKDE3KS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLSgxNikgRGF0YSAvIEluc3RydWN0aW9uCitHcm91bmQgKDE4KS0tLVtHTkRdICAgICAgICAgICAgICBbKzV2XS0tLSgxOSkgTEVEICsKK0dyb3VuZCAoMTkpLS0tW0dORF0KK0dyb3VuZCAoMjApLS0tW0dORF0gICAgICAgICAgICAgIEUgICAgQSAgICAgICAgICAgICBWYWx1ZXM6CitHcm91bmQgKDIxKS0tLVtHTkRdICAgICAgIFtHTkRdLS0tW1AxXS0tLSgxOCkgVmVlICAgILcgUiA9IFJlc2lzdG9yID0gMjIgb2htCitHcm91bmQgKDIyKS0tLVtHTkRdICAgICAgICAgICAgICAgIHwgICAgICAgICAgICAgICAgILcgUDEgPSBQcmVzZ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SBhL0RvY3VtZW50YXRpb24va2VybmVsLWRvY3MudHh0CisrKyBiL0RvY3VtZW50YXRpb24va2VybmVsLWRvY3MudHh0CkBAIC0xLDEwICsxLDEwIEBACiAKLSAgICAgICBJbmRleCBvZiBEb2N1bWVudGF0aW9uIGZvciBQZW9wbGUgSW50ZXJlc3RlZCBpbiBXcml0aW5nIGFuZC9vcgotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKLSAgICAgICAgICAgICAgICAgICAgICBVbmRlcnN0YW5kaW5nIHRoZSBMaW51eCBLZXJuZWwuCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAotICAgICAgICAgICAgICAgSnVhbi1NYXJpYW5vIGRlIEdveWVuZWNoZSA8am1zZXlhc0BkaXQudXBtLmVzPgotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKKyAgICBJbmRleCBvZiBEb2N1bWVudGF0aW9uIGZvciBQZW9wbGUgSW50ZXJlc3RlZCBpbiBXcml0aW5nIGFuZC9vcgorCisgICAgICAgICAgICAgICAgICAgVW5kZXJzdGFuZGluZyB0aGUgTGludXggS2VybmVsLgorCisgICAgICAgICAgSnVhbi1NYXJpYW5vIGRlIEdveWVuZWNoZSA8am1zZXlhc0BkaXQudXBtLmVzPgorCiAvKgogICogVGhlIGxhdGVzdCB2ZXJzaW9uIG9mIHRoaXMgZG9jdW1lbnQgbWF5IGJlIGZvdW5kIGF0OgogICogICBodHRwOi8vd3d3LmRpdC51cG0uZXMvfmptc2V5YXMvbGludXgva2VybmVsL2hhY2tlcnMtZG9jcy5odG1sCkBAIC02MSwxOCArNjEsMTggQEAKICAgICAgICAxMy4tVGhlIExpbnV4IEtlcm5lbCBTb3VyY2VzLCBBLi1MaW51eCBEYXRhIFN0cnVjdHVyZXMsIEIuLVRoZQogICAgICAgIEFscGhhIEFYUCBQcm9jZXNzb3IsIEMuLVVzZWZ1bCBXZWIgYW5kIEZUUCBTaXRlcywgRC4tVG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gICAgICAKLSAgICAgKiBUaXRsZTogIlRoZSBMaW51eCBLZXJuZWwgQm9vayIKLSAgICAgICBBdXRob3I6IFJlbXkgQ2FyZCwgRXJpYyBEdW1hcywgRnJhbmNrIE1ldmVsLgotICAgICAgIFB1Ymxpc2hlcjogSm9obiBXaWxleSAmIFNvbnMuCi0gICAgICAgRGF0ZTogMTk5OC4KLSAgICAgICBJU0JOOiAwLTQ3MS05ODE0MS05Ci0gICAgICAgTm90ZXM6IEVuZ2xpc2ggdHJhbnNsYXRpb24uCi0gICAgICAgCi0gICAgICogVGl0bGU6ICJMaW51eCAyLjAiCi0gICAgICAgQXV0aG9yOiBSZW15IENhcmQsIEVyaWMgRHVtYXMsIEZyYW5jayBNZXZlbC4KLSAgICAgICBQdWJsaXNoZXI6IEdlc3Rp824gMjAwMC4KLSAgICAgICBEYXRlOiAxOTk3LgotICAgICAgIFBhZ2VzOiA1MDEuCi0gICAgICAgSVNCTjogOC00ODAtODgyMDgtNQotICAgICAgIE5vdGVzOiBTcGFuaXNoIHRyYW5zbGF0aW9uLgotICAgICAgIAorCiAgICAgICogVGl0bGU6ICJVbml4IGludGVybmFscyAtLSB0aGUgbmV3IGZyb250aWVycyIKICAgICAgICBBdXRob3I6IFVyZXNoIFZhaGFsaWEuCiAgICAgICAgUHVibGlzaGVyOiBQcmVudGljZSBIYWxsLgogICAgICAgIERhdGU6IDE5OTYuCiAgICAgICAgUGFnZXM6IDYwMC4KICAgICAgICBJU0JOOiAwLTEzLTEwMTkwOC0yCi0gICAgICAgCi0gICAgICogVGl0bGU6ICJMaW51eCBDb3JlIEtlcm5lbCBDb21tZW50YXJ5LiBHdWlkZSB0byBJbnNpZGVyJ3MgS25vd2xlZGdlCi0gICAgICAgb24gdGhlIENvcmUgS2VybmVsIG9mIHRoZSBMaW51eCBDb2RlIgotICAgICAgIEF1dGhvcjogU2NvdHQgTWF4d2VsbC4KLSAgICAgICBQdWJsaXNoZXI6IENvcmlvbGlzLgotICAgICAgIERhdGU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ZW0iCisgICAgICAgQXV0aG9yOiBTYW11ZWwgSi4gTGVmZmxlciwgTWFyc2hhbGwgS2lyayBNY0t1c2ljaywgTWljaGFlbCBKLgorICAgICAgIEthcmVscywgSm9obiBTLiBRdWFydGVybWFuLgorICAgICAgIFB1Ymxpc2hlcjogQWRkaXNvbi1XZXNsZXkuCisgICAgICAgRGF0ZTogMTk4OSAocmVwcmludGVkIHdpdGggY29ycmVjdGlvbnMgb24gT2N0b2JlciwgMTk5MCkuCisgICAgICAgSVNCTjogMC0yMDEtMDYxOTYtMQorCisgICAgICogVGl0bGU6ICJUaGUgRGVzaWduIG9mIHRoZSBVTklYIE9wZXJhdGluZyBTeXN0ZW0iCisgICAgICAgQXV0aG9yOiBNYXVyaWNlIEouIEJhY2guCisgICAgICAgUHVibGlzaGVyOiBQcmVudGljZSBIYWxsLgorICAgICAgIERhdGU6IDE5ODYuCisgICAgICAgUGFnZXM6IDQ3MS4KKyAgICAgICBJU0JOOiAwLTEzLTIwMTc1Ny0xCisKICAgICAgTUlTQ0VMTEFORU9VUzoKLSAgIAorCiAgICAgICogTmFtZTogbGludXgvRG9jdW1lbnRhdGlvbgogICAgICAgIEF1dGhvcjogTWFueS4KICAgICAgICBVUkw6IEp1c3QgbG9vayBpbnNpZGUgeW91ciBrZXJuZWwgc291cmNlcy4KQEAgLTY2MCw3ICs2NDUsNyBAQAogICAgICAgIGluc2lkZSB0aGUgRG9jdW1lbnRhdGlvbiBkaXJlY3RvcnkuIFNvbWUgcGFnZXMgZnJvbSB0aGlzIGRvY3VtZW50CiAgICAgICAgKGluY2x1ZGluZyB0aGlzIGRvY3VtZW50IGl0c2VsZikgaGF2ZSBiZWVuIG1vdmVkIHRoZXJlLCBhbmQgbWlnaHQKICAgICAgICBiZSBtb3JlIHVwIHRvIGRhdGUgdGhhbiB0aGUgd2ViIHZlcnNpb24uCi0gICAgICAgCisKICAgICAgKiBOYW1lOiAiTGludXggU291cmNlIERyaXZlciIKICAgICAgICBVUkw6IGh0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29kZXIgWSBob3Jpem9udGFsIHNjYWxpbmcKKwkJICAgIE5vcm1hbGx5ID0gUmVnIDI4NTQgPj4gMgorLS0tLS0tLS0tLS0tLS0tCisyODQwCisgICAgICBiaXRzIDA6MzEKKwlEZWNvZGVyID8/IHVua25vd24gLSBob3Jpem9udGFsIHNjYWxpbmcKKwkgIFVzdWFsbHkgMHgwMDA4MDUxNAorLS0tLS0tLS0tLS0tLS0tCisyODQ0CisgICAgICBiaXRzIDA6MzEKKwlEZWNvZGVyIFVWIGhvcml6b250YWwgc2NhbGluZworCSAgTm9ybWFsbHkgPSBSZWcgMjg1NCA+PiAyCistLS0tLS0tLS0tLS0tLS0KKzI4NDgKKyAgICAgIGJpdHMgMDozMQorCURlY29kZXIgPz8gdW5rbm93biAtIGhvcml6b250YWwgc2NhbGluZworCSAgVXN1YWxseSAweDAwMTAwNTE0CistLS0tLS0tLS0tLS0tLS0KKzI4NEMKKyAgICAgIGJpdHMgMDozMQorCURlY29kZXIgPz8gdW5rbm93biAtIFkgcGxhbmUKKwkgIFVzdWFsbHkgMHgwMDIwMDAyMAorLS0tLS0tLS0tLS0tLS0tCisyODUwCisgICAgICBiaXRzIDA6MzEKKwlEZWNvZGVyID8/IHVua25vd24gLSBVViBwbGFuZQorCSAgVXN1YWxseSAweDAwMjAwMDIwCistLS0tLS0tLS0tLS0tLS0KKzI4NTQKKyAgICAgIGJpdHMgMDozMQorCURlY29kZXIgJ21hc3RlcicgdmFsdWUgZm9yIGhvcml6b250YWwgc2NhbGluZworLS0tLS0tLS0tLS0tLS0tCisyODU4CisgICAgICBiaXRzIDA6MzEKKwlEZWNvZGVyID8/IHVua25vd24KKwkgIFVzdWFsbHkgMAorLS0tLS0tLS0tLS0tLS0tCisyODVDCisgICAgICBiaXRzIDA6MzEKKwlEZWNvZGVyID8/IHVua25vd24KKwkgIE5vcm1hbGx5ID0gUmVnIDI4NTQgPj4gMQorLS0tLS0tLS0tLS0tLS0tCisyODYwCisgICAgICBiaXRzIDA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IDB4WFggICAgICAgICAgTm90IHVzZWQKKzB4MTAgICAgMHhYWCAgICAgICAgICBOb3QgdXNlZAorMHgxMSAgICAweFhYICAgICAgICAgIE5vdCB1c2VkCiAKLVRoZSBmb2xsb3dpbmcgYnl0ZXMgYXJlIHVzZWQgYnkgdGhlIFNOOUMxMDMgYnJpZGdlIG9ubHk6CitUaGUgZm9sbG93aW5nIHRhYmxlIGRlc2NyaWJlcyB0aGUgZnJhbWUgaGVhZGVyIGV4cG9ydGVkIGJ5IHRoZSBTTjlDMTAzOgogCi0weDBDICAgIDB4WFggICAgICAgICAgVW5rbm93biBtZWFuaW5nCi0weDBEICAgIDB4WFggICAgICAgICAgVW5rbm93biBtZWFuaW5nCi0weDBFICAgIDB4WFggICAgICAgICAgVW5rbm93biBtZWFuaW5nCi0weDBGICAgIDB4WFggICAgICAgICAgVW5rbm93biBtZWFuaW5nCi0weDEwICAgIDB4WFggICAgICAgICAgVW5rbm93biBtZWFuaW5nCi0weDExICAgIDB4WFggICAgICAgICAgVW5rbm93biBtZWFuaW5nCitCeXRlICMgIFZhbHVlIG9yIGJpdHMgRGVzY3JpcHRpb24KKy0tLS0tLSAgLS0tLS0tLS0tLS0tLSAtLS0tLS0tLS0tLQorMHgwMCAgICAweEZGICAgICAgICAgIEZyYW1lIHN5bmNocm9uaXNhdGlvbiBwYXR0ZXJuCisweDAxICAgIDB4RkYgICAgICAgICAgRnJhbWUgc3luY2hyb25pc2F0aW9uIHBhdHRlcm4KKzB4MDIgICAgMHgwMCAgICAgICAgICBGcmFtZSBzeW5jaHJvbmlzYXRpb24gcGF0dGVybgorMHgwMyAgICAweEM0ICAgICAgICAgIEZyYW1lIHN5bmNocm9uaXNhdGlvbiBwYXR0ZXJuCisweDA0ICAgIDB4QzQgICAgICAgICAgRnJhbWUgc3luY2hyb25pc2F0aW9uIHBhdHRlcm4KKzB4MDUgICAgMHg5NiAgICAgICAgICBGcmFtZSBzeW5jaHJvbmlzYXRpb24gcGF0dGVybgorMHg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bGwgYXBlcnR1cmUuCisgICAgYWxsb3dkYWMgICAgICAgICAgIEFsbG93IGRvdWJsZS1hZGRyZXNzIGN5Y2xlIChEQUMpIG1vZGUsIGkuZS4gRE1BID40R0IuCisgICAgICAgICAgICAgICAgICAgICAgIERBQyBpcyB1c2VkIHdpdGggMzItYml0IFBDSSB0byBwdXNoIGEgNjQtYml0IGFkZHJlc3MgaW4KKyAgICAgICAgICAgICAgICAgICAgICAgdHdvIGN5Y2xlcy4gV2hlbiBvZmYgYWxsIERNQSBvdmVyID40R0IgaXMgZm9yY2VkIHRocm91Z2gKKyAgICAgICAgICAgICAgICAgICAgICAgYW4gSU9NTVUgb3Igc29mdHdhcmUgYm91bmNlIGJ1ZmZlcmluZy4KKyAgICBub2RhYyAgICAgICAgICAgICAgRm9yYmlkIERBQyBtb2RlLCBpLmUuIERNQSA+NEdCLgorICAgIHBhbmljICAgICAgICAgICAgICBBbHdheXMgcGFuaWMgd2hlbiBJT01NVSBvdmVyZmxvd3MuCisgICAgY2FsZ2FyeSAgICAgICAgICAgIFVzZSB0aGUgQ2FsZ2FyeSBJT01NVSBpZiBpdCBpcyBhdmFpbGFibGUKKworICBpb21tdSBvcHRpb25zIG9ubHkgcmVsZXZhbnQgdG8gdGhlIHNvZnR3YXJlIGJvdW5jZSBidWZmZXJpbmcgKFNXSU9UTEIpIElPTU1VCisgIGltcGxlbWVudGF0aW9uOgorICAgIHN3aW90bGI9PHBhZ2VzPlssZm9yY2VdCisgICAgPHBhZ2VzPiAgICAgICAgICAgIFByZXJlc2VydmUgdGhhdCBtYW55IDEyOEsgcGFnZXMgZm9yIHRoZSBzb2Z0d2FyZSBJTworICAgICAgICAgICAgICAgICAgICAgICBib3VuY2UgYnVmZmVyaW5nLgorICAgIGZvcmNlICAgICAgICAgICAgICBGb3JjZSBhbGwgSU8gdGhyb3VnaCB0aGUgc29mdHdhcmUgVExCLgorCisgIFNldHRpbmdzIGZvciB0aGUgSUJNIENhbGdhcnkgaGFyZHdhcm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9QQVJUUyBpcyBub3Qgc2V0CitDT05GSUdfTVREX0NNRExJTkVfUEFSVFM9eQorIyBDT05GSUdfTVREX0FGU19QQVJUUyBpcyBub3Qgc2V0CisKKyMKKyMgVXNlciBNb2R1bGVzIEFuZCBUcmFuc2xhdGlvbiBMYXllcnMKKyMKK0NPTkZJR19NVERfQ0hBUj15CitDT05GSUdfTVREX0JMS0RFVlM9eQorQ09ORklHX01URF9CTE9DSz15CisjIENPTkZJR19GVEwgaXMgbm90IHNldAorIyBDT05GSUdfTkZUTCBpcyBub3Qgc2V0CisjIENPTkZJR19JTkZUTCBpcyBub3Qgc2V0CisjIENPTkZJR19SRkRfRlRMIGlzIG5vdCBzZXQKKyMgQ09ORklHX1NTRkRDIGlzIG5vdCBzZXQKKworIworIyBSQU0vUk9NL0ZsYXNoIGNoaXAgZHJpdmVycworIworIyBDT05GSUdfTVREX0NGSSBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfSkVERUNQUk9CRSBpcyBub3Qgc2V0CitDT05GSUdfTVREX01BUF9CQU5LX1dJRFRIXzE9eQorQ09ORklHX01URF9NQVBfQkFOS19XSURUSF8yPXkKK0NPTkZJR19NVERfTUFQX0JBTktfV0lEVEhfND15CisjIENPTkZJR19NVERfTUFQX0JBTktfV0lEVEhfOCBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfTUFQX0JBTktfV0lEVEhfMTYgaXMgbm90IHNldAorIyBDT05GSUdfTVREX01BUF9CQU5LX1dJRFRIXzMyIGlzIG5vdCBzZXQKK0NPTkZJR19NVERfQ0ZJX0kxPXkKK0NPTkZJR19NVERfQ0ZJX0kyPXkKKyMgQ09ORklHX01URF9DRklfSTQgaXMgbm90IHNldAorIyBDT05GSUdfTVREX0NGSV9JOCBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfUkFNIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9ST00gaXMgbm90IHNldAorIyBDT05GSUdfTVREX0FCU0VOVCBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfT0JTT0xFVEVfQ0hJUFMgaXMgbm90IHNldAorCisjCisjIE1hcHBpbmcgZHJpdmVycyBmb3IgY2hpcCBhY2Nlc3MKKyMKKyMgQ09ORklHX01URF9DT01QTEVYX01BUFBJTkdTIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9QTEFUUkFNIGlzIG5vdCBzZXQKKworIworIyBTZWxmLWNvbnRhaW5lZCBNVEQgZGV2aWNlIGRyaXZlcnMKKyMKK0NPTkZJR19NVERfREFUQUZMQVNIPXkKKyMgQ09ORklHX01URF9NMjVQODAgaXMgbm90IHNldAorIyBDT05GSUdfTVREX1NMUkFNIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9QSFJBTSBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfTVREUkFNIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9CTE9DSzJNVEQgaXMgbm90IHNldAorCisjCisjIERpc2stT24tQ2hpcCBEZXZpY2UgRHJpdmVycworIworIyBDT05GSUdfTVREX0RPQzIwMDAgaXMgbm90IHNldAorIyBDT05GSUdfTVREX0RPQzIwMDEgaXMgbm90IHNldAorIyBDT05GSUdfTVREX0RPQzIwMDFQTFVTIGlzIG5vdCBzZXQKKworIworIyBOQU5EIEZsYXNoIERldmljZSBEcml2ZXJzCisjCitDT05GSUdfTVREX05BTkQ9eQorIyBDT05GSUdfTVREX05BTkRfVkVSSUZZX1dSSVRFIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9OQU5EX0VDQ19TTUMgaXMgbm90IHNldAorQ09ORklHX01URF9OQU5EX0lEUz15CisjIENPTkZJR19NVERfTkFORF9ESVNLT05DSElQIGlzIG5vdCBzZXQKK0NPTkZJR19NVERfTkFORF9BVDkxPXkKKyMgQ09ORklHX01URF9OQU5EX05BTkRTSU0gaXMgbm90IHNldAorCisjCisjIE9uZU5BTkQgRmxhc2ggRGV2aWNlIERyaXZlcnMKKyMKKyMgQ09ORklHX01URF9PTkVOQU5EIGlz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gMTM5NCAoRmlyZVdpcmUpIHN1cHBvcnQKKyMKKworIworIyBJMk8gZGV2aWNlIHN1cHBvcnQKKyMKKworIworIyBOZXR3b3JrIGRldmljZSBzdXBwb3J0CisjCitDT05GSUdfTkVUREVWSUNFUz15CisjIENPTkZJR19EVU1NWSBpcyBub3Qgc2V0CisjIENPTkZJR19CT05ESU5HIGlzIG5vdCBzZXQKKyMgQ09ORklHX0VRVUFMSVpFUiBpcyBub3Qgc2V0CisjIENPTkZJR19UVU4gaXMgbm90IHNldAorCisjCisjIFBIWSBkZXZpY2Ugc3VwcG9ydAorIworIyBDT05GSUdfUEhZTElCIGlzIG5vdCBzZXQKKworIworIyBFdGhlcm5ldCAoMTAgb3IgMTAwTWJpdCkKKyMKK0NPTkZJR19ORVRfRVRIRVJORVQ9eQorQ09ORklHX01JST15CisjIENPTkZJR19TTUM5MVggaXMgbm90IHNldAorIyBDT05GSUdfRE05MDAwIGlzIG5vdCBzZXQKKworIworIyBFdGhlcm5ldCAoMTAwMCBNYml0KQorIworCisjCisjIEV0aGVybmV0ICgxMDAwMCBNYml0KQorIworCisjCisjIFRva2VuIFJpbmcgZGV2aWNlcworIworCisjCisjIFdpcmVsZXNzIExBTiAobm9uLWhhbXJhZGlvKQorIworIyBDT05GSUdfTkVUX1JBRElPIGlzIG5vdCBzZXQKKworIworIyBXYW4gaW50ZXJmYWNlcworIworIyBDT05GSUdfV0FOIGlzIG5vdCBzZXQKKyMgQ09ORklHX1BQUCBpcyBub3Qgc2V0CisjIENPTkZJR19TTElQIGlzIG5vdCBzZXQKKyMgQ09ORklHX1NIQVBFUiBpcyBub3Qgc2V0CisjIENPTkZJR19ORVRDT05TT0xFIGlzIG5vdCBzZXQKKyMgQ09ORklHX05FVFBPTEwgaXMgbm90IHNldAorIyBDT05GSUdfTkVUX1BPTExfQ09OVFJPTExFUiBpcyBub3Qgc2V0CisKKyMKKyMgSVNETiBzdWJzeXN0ZW0KKyMKKyMgQ09ORklHX0lTRE4gaXMgb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RlbXMKKyMKKyMgQ09ORklHX0FERlNfRlMgaXMgbm90IHNldAorIyBDT05GSUdfQUZGU19GUyBpcyBub3Qgc2V0CisjIENPTkZJR19IRlNfRlMgaXMgbm90IHNldAorIyBDT05GSUdfSEZTUExVU19GUyBpcyBub3Qgc2V0CisjIENPTkZJR19CRUZTX0ZTIGlzIG5vdCBzZXQKKyMgQ09ORklHX0JGU19GUyBpcyBub3Qgc2V0CisjIENPTkZJR19FRlNfRlMgaXMgbm90IHNldAorIyBDT05GSUdfQ1JBTUZTIGlzIG5vdCBzZXQKKyMgQ09ORklHX1ZYRlNfRlMgaXMgbm90IHNldAorIyBDT05GSUdfSFBGU19GUyBpcyBub3Qgc2V0CisjIENPTkZJR19RTlg0RlNfRlMgaXMgbm90IHNldAorIyBDT05GSUdfU1lTVl9GUyBpcyBub3Qgc2V0CisjIENPTkZJR19VRlNfRlMgaXMgbm90IHNldAorCisjCisjIFBhcnRpdGlvbiBUeXBlcworIworIyBDT05GSUdfUEFSVElUSU9OX0FEVkFOQ0VEIGlzIG5vdCBzZXQKK0NPTkZJR19NU0RPU19QQVJUSVRJT049eQorCisjCisjIE5hdGl2ZSBMYW5ndWFnZSBTdXBwb3J0CisjCisjIENPTkZJR19OTFMgaXMgbm90IHNldAorCisjCisjIFByb2ZpbGluZyBzdXBwb3J0CisjCisjIENPTkZJR19QUk9GSUxJTkcgaXMgbm90IHNldAorCisjCisjIEtlcm5lbCBoYWNraW5nCisjCisjIENPTkZJR19QUklOVEtfVElNRSBpcyBub3Qgc2V0CisjIENPTkZJR19FTkFCTEVfTVVTVF9DSEVDSyBpcyBub3Qgc2V0CisjIENPTkZJR19NQUdJQ19TWVNSUSBpcyBub3Qgc2V0CisjIENPTkZJR19VTlVTRURfU1lNQk9MUyBpcyBub3Qgc2V0CisjIENPTkZJR19ERUJVR19GUyBpcyBub3Qgc2V0CisjIENPTkZJR19IRUFERVJTX0NIRUNLIGlzIG5vdCBzZXQKK0NPTkZJR19ERUJVR19LR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b19kaXJlY3Rpb25faW5wdXQodW5zaWduZWQgcGluKQoreworCXZvaWQgX19pb21lbQkqcGlvID0gcGluX3RvX2NvbnRyb2xsZXIocGluKTsKKwl1bnNpZ25lZAltYXNrID0gcGluX3RvX21hc2socGluKTsKKworCWlmICghcGlvIHx8ICEoX19yYXdfcmVhZGwocGlvICsgUElPX1BTUikgJiBtYXNrKSkKKwkJcmV0dXJuIC1FSU5WQUw7CisJX19yYXdfd3JpdGVsKG1hc2ssIHBpbyArIFBJT19PRVIpOworCXJldHVybiAwOworfQorRVhQT1JUX1NZTUJPTChncGlvX2RpcmVjdGlvbl9pbnB1dCk7CisKK2ludCBncGlvX2RpcmVjdGlvbl9vdXRwdXQodW5zaWduZWQgcGluKQoreworCXZvaWQgX19pb21lbQkqcGlvID0gcGluX3RvX2NvbnRyb2xsZXIocGluKTsKKwl1bnNpZ25lZAltYXNrID0gcGluX3RvX21hc2socGluKTsKKworCWlmICghcGlvIHx8ICEoX19yYXdfcmVhZGwocGlvICsgUElPX1BTUikgJiBtYXNrKSkKKwkJcmV0dXJuIC1FSU5WQUw7CisJX19yYXdfd3JpdGVsKG1hc2ssIHBpbyArIFBJT19PRVIpOworCXJldHVybiAwOworfQorRVhQT1JUX1NZTUJPTChncGlvX2RpcmVjdGlvbl9vdXRwdXQpOworCisvKi0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tKi8KKworLyoKKyAqIGFzc3VtaW5nIHRoZSBwaW4gaXMgbXV4ZWQgYXMgYSBncGlvIG91dHB1dCwgc2V0IGl0cyB2YWx1ZS4KKyAqLworaW50IGF0OTFfc2V0X2dwaW9fdmFsdWUodW5zaWduZWQgcGluLCBpbnQgdmFsdWUpCit7CisJdm9pZCBfX2lvbWVtCSpwaW8gPSBwaW5fdG9fY29udHJvbGxlcihwaW4pOworCXVuc2lnbmVkCW1hc2sgPSBwa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ICAgLmVuZCAgICA9IElSUV9FUDkzWFhfRVRIRVJORVQsCisgICAgICAgICAgICAgICAuZmxhZ3MgID0gSU9SRVNPVVJDRV9JUlEsCisgICAgICAgfQorfTsKKworc3RhdGljIHN0cnVjdCBwbGF0Zm9ybV9kZXZpY2UgbWljcm85X2V0aF9kZXZpY2UgPSB7CisgICAgICAgLm5hbWUgICAgICAgICAgID0gImVwOTN4eC1ldGgiLAorICAgICAgIC5pZCAgICAgICAgICAgICA9IC0xLAorICAgICAgIC5kZXYgICAgICAgICAgICA9IHsKKyAgICAgICAgICAgICAgIC5wbGF0Zm9ybV9kYXRhICA9ICZtaWNybzlfZXRoX2RhdGEsCisgICAgICAgfSwKKyAgICAgICAubnVtX3Jlc291cmNlcyA9IEFSUkFZX1NJWkUobWljcm85X2V0aF9yZXNvdXJjZSksCisgICAgICAgLnJlc291cmNlICAgICAgID0gbWljcm85X2V0aF9yZXNvdXJjZSwKK307CisKK3N0YXRpYyB2b2lkIF9faW5pdCBtaWNybzlfZXRoX2luaXQodm9pZCkKK3sKKyAgICAgICBtZW1jcHkobWljcm85X2V0aF9kYXRhLmRldl9hZGRyLAorICAgICAgICAgICAgICAgKHZvaWQgKikoRVA5M1hYX0VUSEVSTkVUX0JBU0UgKyAweDUwKSwgNik7CisgICAgICAgcGxhdGZvcm1fZGV2aWNlX3JlZ2lzdGVyKCZtaWNybzlfZXRoX2RldmljZSk7Cit9CisKK3N0YXRpYyB2b2lkIF9faW5pdCBtaWNybzlfaW5pdCh2b2lkKQoreworICAgICAgIG1pY3JvOV9ldGhfaW5pdCgpOworfQorCisvKgorICogTWljcm85LUgKKyAqLworI2lmZGVmIENPTkZJR19NQUNIX01JQ1JPOUgKK3N0YXRpYyBzdHJ1Y3QgcGh5c21hcF9mbGFzaF9kYXRhIG1pY3JvOWhfZmxhc2hfZGF0YSA9IHsKKyAgICAgICAud2lkdGggICAgICAgICAgPSA0LAorfTsKKworc3RhdGljIHN0cnVjdCByZXNvdXJjZSBtaWNybzloX2ZsYXNoX3Jlc291cmNlID0geworICAgICAgIC5zdGFydCAgICAgICAgICA9IDB4MTAwMDAwMDAsCisgICAgICAgLmVuZCAgICAgICAgICAgID0gMHgxM2ZmZmZmZiwKKyAgICAgICAuZmxhZ3MgICAgICAgICAgPSBJT1JFU09VUkNFX01FTSwKK307CisKK3N0YXRpYyBzdHJ1Y3QgcGxhdGZvcm1fZGV2aWNlIG1pY3JvOWhfZmxhc2ggPSB7CisgICAgICAgLm5hbWUgICAgICAgICAgID0gInBoeXNtYXAtZmxhc2giLAorICAgICAgIC5pZCAgICAgICAgICAgICA9IDAsCisgICAgICAgLmRldiAgICAgICAgICAgID0geworICAgICAgICAgICAgICAgLnBsYXRmb3JtX2RhdGEgID0gJm1pY3JvOWhfZmxhc2hfZGF0YSwKKyAgICAgICB9LAorICAgICAgIC5udW1fcmVzb3VyY2VzICA9IDEsCisgICAgICAgLnJlc291cmNlICAgICAgID0gJm1pY3JvOWhfZmxhc2hfcmVzb3VyY2UsCit9OworCitzdGF0aWMgdm9pZCBfX2luaXQgbWljcm85aF9pbml0KHZvaWQpCit7CisgICAgICAgcGxhdGZvcm1fZGV2aWNlX3JlZ2lzdGVyKCZtaWNybzloX2ZsYXNoKTsKK30KKworc3RhdGljIHZvaWQgX19pbml0IG1pY3JvOWhfaW5pdF9tYWNoaW5lKHZvaWQpCit7CisgICAgICAgZXA5M3h4X2luaXRfZGV2aWNlcygpOworICAgICAgIG1pY3JvOV9pbml0KCk7CisgICAgICAgbWljcm85aF9pbml0KCk7Cit9CisKK01BQ0hJTkVfU1RBUlQoTUlDUk85LCAiQ29udGVjIEh5cGVyY29udHJvbCBNaWNybzktSCIpCisgICAgICAgLyogTWFpbnRhaW5lcjogTWFuZnJlZCBHcnViZXIgPG1hbmZyZWQuZ3J1YmVyQGNvbnRlYy5hdD4gKi8KKyAgICAgICAucGh5c19pbyAgICAgICAgPSBFUDkzWFhfQVBCX1BIWVNfQkFTRSwKKyAgICAgICAuaW9fcGdfb2Zmc3QgICAgPSAoKEVQOTNYWF9BUEJfVklSVF9CQVNFKSA+PiAxOCkgJiAweGZmZmMsCisgICAgICAgLmJvb3RfcGFyYW1zICAgID0gMHgwMDAwMDEwMCwKKyAgICAgICAubWFwX2lvICAgICAgICAgPSBlcDkzeHhfbWFwX2lvLAorICAgICAgIC5pbml0X2lycSAgICAgICA9IGVwOTN4eF9pbml0X2lycSwKKyAgICAgICAudGltZXIgICAgICAgICAgPSAmZXA5M3h4X3RpbWVyLAorICAgICAgIC5pbml0X21hY2hpbmUgICA9IG1pY3JvOWhfaW5pdF9tYWNoaW5lLAorTUFDSElORV9FTkQKKyNlbmRpZgorCisvKgorICogTWljcm85LU0KKyAqLworI2lmZGVmIENPTkZJR19NQUNIX01JQ1JPOU0KK3N0YXRpYyB2b2lkIF9faW5pdCBtaWNybzltX2luaXRfbWFjaGluZSh2b2lkKQoreworICAgICAgIGVwOTN4eF9pbml0X2RldmljZXMoKTsKKyAgICAgICBtaWNybzlfaW5pdCgpOworfQorCitNQUNISU5FX1NUQVJUKE1JQ1JPOU0sICJDb250ZWMgSHlwZXJjb250cm9sIE1pY3JvOS1NIikKKyAgICAgICAvKiBNYWludGFpbmVyOiBNYW5mcmVkIEdydWJlciA8bWFuZnJlZC5ncnViZXJAY29udGVjLmF0PiAqLworICAgICAgIC5waHlzX2lvICAgICAgICA9IEVQOTNYWF9BUEJfUEhZU19CQVNFLAorICAgICAgIC5pb19wZ19vZmZzdCAgICA9ICgoRVA5M1hYX0FQQl9WSVJUX0JBU0UpID4+IDE4KSAmIDB4ZmZmYywKKyAgICAgICAuYm9vdF9wYXJhbXMgICAgPSAweDAwMDAwMTAwLAorICAgICAgIC5tYXBfaW8gICAgICAgICA9IGVwOTN4eF9tYXBfaW8sCisgICAgICAgLmluaXRfaXJxICAgICAgID0gZXA5M3h4X2luaXRfaXJxLAorICAgICAgIC50aW1lciAgICAgICAgICA9ICZlcDkzeHhfdGltZXIsCisgICAgICAgLmluaXRfbW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SAwLAorCX0sCisJWzFdID0geworCQkubmFtZQkJPSAicGNsayIsCisJCS5kaXZpc29yCT0gMSwKKwkJLm1pbl9iYXVkCT0gMCwKKwkJLm1heF9iYXVkCT0gMCwKKwl9Cit9OworCisKK3N0YXRpYyBzdHJ1Y3QgczNjMjQxMF91YXJ0Y2ZnIGFudWJpc191YXJ0Y2Znc1tdIF9faW5pdGRhdGEgPSB7CisJWzBdID0geworCQkuaHdwb3J0CSAgICAgPSAwLAorCQkuZmxhZ3MJICAgICA9IDAsCisJCS51Y29uCSAgICAgPSBVQ09OLAorCQkudWxjb24JICAgICA9IFVMQ09OLAorCQkudWZjb24JICAgICA9IFVGQ09OLAorCQkuY2xvY2tzCSAgICAgPSBhbnViaXNfc2VyaWFsX2Nsb2NrcywKKwkJLmNsb2Nrc19zaXplID0gQVJSQVlfU0laRShhbnViaXNfc2VyaWFsX2Nsb2NrcyksCisJfSwKKwlbMV0gPSB7CisJCS5od3BvcnQJICAgICA9IDIsCisJCS5mbGFncwkgICAgID0gMCwKKwkJLnVjb24JICAgICA9IFVDT04sCisJCS51bGNvbgkgICAgID0gVUxDT04sCisJCS51ZmNvbgkgICAgID0gVUZDT04sCisJCS5jbG9ja3MJICAgICA9IGFudWJpc19zZXJpYWxfY2xvY2tzLAorCQkuY2xvY2tzX3NpemUgPSBBUlJBWV9TSVpFKGFudWJpc19zZXJpYWxfY2xvY2tzKSwKKwl9LAorfTsKKworLyogTkFORCBGbGFzaCBvbiBBbnViaXMgYm9hcmQgKi8KKworc3RhdGljIGludCBleHRlcm5hbF9tYXBbXSAgID0geyAyIH07CitzdGF0aWMgaW50IGNoaXAwX21hcFtdICAgICAgPSB7IDAgfTsKK3N0YXRpYyBpbnQgY2hpcDFfbWFwW10gICAgICA9IHsgMSB9OworCitzdGF0aWMgc3RydWN0IG10ZF9wYXJ0aXRpb24gYW51YmlzX2RlZmF1bHRfbmFuZF9wYXJ0W10gPSB7CisJWzBdID0geworCQkubmFtZQk9ICJCb290IEF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isJLm1hc2sJICAgID0gczNjMjQ0M19pcnFfZG1hX21hc2ssCisJLnVubWFzawkgICAgPSBzM2MyNDQzX2lycV9kbWFfdW5tYXNrLAorCS5hY2sJICAgID0gczNjMjQ0M19pcnFfZG1hX2FjaywKK307CisKKworLyogVUFSVDMgc3ViIGludGVycnVwdHMgKi8KKworc3RhdGljIHZvaWQgczNjMjQ0M19pcnFfZGVtdXhfdWFydDModW5zaWduZWQgaW50IGlycSwgc3RydWN0IGlycV9kZXNjICpkZXNjKQoreworCXMzYzI0NDNfaXJxX2RlbXV4KElSUV9TM0MyNDQzX1VBUlQzLCAzKTsKK30KKworI2RlZmluZSBJTlRNU0tfVUFSVDMJKDFVTCA8PCAoSVJRX1MzQzI0NDNfVUFSVDMgLSBJUlFfRUlOVDApKQorI2RlZmluZSBTVUJNU0tfVUFSVDMJKDB4ZiA8PCAoSVJRX1MzQzI0NDNfUlgzIC0gUzNDMjQxMF9JUlFTVUIoMCkpKQorCisKK3N0YXRpYyB2b2lkIHMzYzI0NDNfaXJxX3VhcnQzX21hc2sodW5zaWduZWQgaW50IGlycW5vKQoreworCXMzY19pcnFzdWJfbWFzayhpcnFubywgSU5UTVNLX1VBUlQzLCBTVUJNU0tfVUFSVDMpOworfQorCitzdGF0aWMgdm9pZCBzM2MyNDQzX2lycV91YXJ0M191bm1hc2sodW5zaWduZWQgaW50IGlycW5vKQoreworCXMzY19pcnFzdWJfdW5tYXNrKGlycW5vLCBJTlRNU0tfVUFSVDMpOworfQorCitzdGF0aWMgdm9pZCBzM2MyNDQzX2lycV91YXJ0M19hY2sodW5zaWduZWQgaW50IGlycW5vKQoreworCXMzY19pcnFzdWJfbWFza2FjayhpcnFubywgSU5UTVNLX1VBUlQzLCBTVUJNU0tfVUFSVDMpOworfQorCitzdGF0aWMgc3RydWN0IGlycV9jaGlwIHMzYzI0NDNfaXJxX3VhcnQzID0geworCS5tYXNrCSAgICA9IHMzYzI0NDNfaXJxX3VhcnQzX21hc2ssCisJLnVubW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orCS5udW1fcmVzb3VyY2VzCSAgPSBBUlJBWV9TSVpFKHMzY19zcGkwX3Jlc291cmNlKSwKKwkucmVzb3VyY2UJICA9IHMzY19zcGkwX3Jlc291cmNlLAorICAgICAgICAuZGV2ICAgICAgICAgICAgICA9IHsKKyAgICAgICAgICAgICAgICAuZG1hX21hc2sgPSAmczNjX2RldmljZV9zcGkwX2RtYW1hc2ssCisgICAgICAgICAgICAgICAgLmNvaGVyZW50X2RtYV9tYXNrID0gMHhmZmZmZmZmZlVMCisgICAgICAgIH0KK307CisKK0VYUE9SVF9TWU1CT0woczNjX2RldmljZV9zcGkwKTsKKworLyogU1BJICgxKSAqLworCitzdGF0aWMgc3RydWN0IHJlc291cmNlIHMzY19zcGkxX3Jlc291cmNlW10gPSB7CisJWzBdID0geworCQkuc3RhcnQgPSBTM0MyNFhYX1BBX1NQSSArIDB4MjAsCisJCS5lbmQgICA9IFMzQzI0WFhfUEFfU1BJICsgMHgyMCArIDB4MWYsCisJCS5mbGFncyA9IElPUkVTT1VSQ0VfTUVNLAorCX0sCisJWzFdID0geworCQkuc3RhcnQgPSBJUlFfU1BJMSwKKwkJLmVuZCAgID0gSVJRX1NQSTEsCisJCS5mbGFncyA9IElPUkVTT1VSQ0VfSVJRLAorCX0KKworfTsKKworc3RhdGljIHU2NCBzM2NfZGV2aWNlX3NwaTFfZG1hbWFzayA9IDB4ZmZmZmZmZmZVTDsKKworc3RydWN0IHBsYXRmb3JtX2RldmljZSBzM2NfZGV2aWNlX3NwaTEgPSB7CisJLm5hbWUJCSAgPSAiczNjMjQxMC1zcGkiLAorCS5pZAkJICA9IDEsCisJLm51bV9yZXNvdXJjZXMJICA9IEFSUkFZX1NJWkUoczNjX3NwaTFfcmVzb3VyY2UpLAorCS5yZXNvdXJjZQkgID0gczNjX3NwaTFfcmVzb3VyY2UsCisgICAgICAgIC5kZXYgICAgICAgICAgICAgID0geworICAgICAgICAgICAgICAgIC5kbWFfbWFzayA9ICZzM2NfZGV2aWNlX3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UKK307CisKK3N0YXRpYyB2b2lkCitzM2NfaXJxZXh0X21hc2sodW5zaWduZWQgaW50IGlycW5vKQoreworCXVuc2lnbmVkIGxvbmcgbWFzazsKKworCWlycW5vIC09IEVYVElOVF9PRkY7CisKKwltYXNrID0gX19yYXdfcmVhZGwoUzNDMjRYWF9FSU5UTUFTSyk7CisJbWFzayB8PSAoIDFVTCA8PCBpcnFubyk7CisJX19yYXdfd3JpdGVsKG1hc2ssIFMzQzI0WFhfRUlOVE1BU0spOworfQorCitzdGF0aWMgdm9pZAorczNjX2lycWV4dF9hY2sodW5zaWduZWQgaW50IGlycW5vKQoreworCXVuc2lnbmVkIGxvbmcgcmVxOworCXVuc2lnbmVkIGxvbmcgYml0OworCXVuc2lnbmVkIGxvbmcgbWFzazsKKworCWJpdCA9IDFVTCA8PCAoaXJxbm8gLSBFWFRJTlRfT0ZGKTsKKworCW1hc2sgPSBfX3Jhd19yZWFkbChTM0MyNFhYX0VJTlRNQVNLKTsKKworCV9fcmF3X3dyaXRlbChiaXQsIFMzQzI0WFhfRUlOVFBFTkQpOworCisJcmVxID0gX19yYXdfcmVhZGwoUzNDMjRYWF9FSU5UUEVORCk7CisJcmVxICY9IH5tYXNrOworCisJLyogbm90IHN1cmUgaWYgd2Ugc2hvdWxkIGJlIGFja2luZyB0aGUgcGFyZW50IGlycS4uLiAqLworCisJaWYgKGlycW5vIDw9IElSUV9FSU5UNyApIHsKKwkJaWYgKChyZXEgJiAweGYwKSA9PSAwKQorCQkJczNjX2lycV9hY2soSVJRX0VJTlQ0dDcpOworCX0gZWxzZSB7CisJCWlmICgocmVxID4+IDgpID09IDApCisJCQlzM2NfaXJxX2FjayhJUlFfRUlOVDh0MjMpOworCX0KK30KKworc3RhdGljIHZvaWQKK3MzY19pcnFleHRfdW5tYXNrKHVuc2lnbmVkIGludCBpcnFubykKK3sKKwl1bnNpZ25lZCBsb25nIG1hc2s7CisKKwlpcnFubyAtPSBFWFRJTlRfT0ZGOworCisJbWFzayA9I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HMzY19pcnFfdWFydDBfdW5tYXNrLAorCS5hY2sJCT0gczNjX2lycV91YXJ0MF9hY2ssCit9OworCisvKiBVQVJUMSAqLworCitzdGF0aWMgdm9pZAorczNjX2lycV91YXJ0MV9tYXNrKHVuc2lnbmVkIGludCBpcnFubykKK3sKKwlzM2NfaXJxc3ViX21hc2soaXJxbm8sIElOVE1TS19VQVJUMSwgNyA8PCAzKTsKK30KKworc3RhdGljIHZvaWQKK3MzY19pcnFfdWFydDFfdW5tYXNrKHVuc2lnbmVkIGludCBpcnFubykKK3sKKwlzM2NfaXJxc3ViX3VubWFzayhpcnFubywgSU5UTVNLX1VBUlQxKTsKK30KKworc3RhdGljIHZvaWQKK3MzY19pcnFfdWFydDFfYWNrKHVuc2lnbmVkIGludCBpcnFubykKK3sKKwlzM2NfaXJxc3ViX21hc2thY2soaXJxbm8sIElOVE1TS19VQVJUMSwgNyA8PCAzKTsKK30KKworc3RhdGljIHN0cnVjdCBpcnFfY2hpcCBzM2NfaXJxX3VhcnQxID0geworCS5uYW1lCQk9ICJzM2MtdWFydDEiLAorCS5tYXNrCQk9IHMzY19pcnFfdWFydDFfbWFzaywKKwkudW5tYXNrCQk9IHMzY19pcnFfdWFydDFfdW5tYXNrLAorCS5hY2sJCT0gczNjX2lycV91YXJ0MV9hY2ssCit9OworCisvKiBVQVJUMiAqLworCitzdGF0aWMgdm9pZAorczNjX2lycV91YXJ0Ml9tYXNrKHVuc2lnbmVkIGludCBpcnFubykKK3sKKwlzM2NfaXJxc3ViX21hc2soaXJxbm8sIElOVE1TS19VQVJUMiwgNyA8PCA2KTsKK30KKworc3RhdGljIHZvaWQKK3MzY19pcnFfdWFydDJfdW5tYXNrKHVuc2lnbmVkIGludCBpcnFubykKK3sKKwlzM2NfaXJxc3ViX3VubWFzayhpcnFubywgSU5UTVNLX1VBUlQyKTsKK30KKworc3RhdGljIHZvaWQKK3MzY19pcnFfdWFydDJfYWNrKHVuc2lnbmVkIGludCBpcnFubykKK3sKKwlzM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BNTkVNX0NBTEw7CisJCQkJcGF0Y2hfb2Zmc2V0KGluc25zLCBpcnFfc2F2ZV9kaXNhYmxlX2NhbGxvdXQpOworCQkJCXJldHVybiA1OworCQkJfQorCQljYXNlIFBBUkFWSVJUX0lOVEVSUlVQVF9SRVRVUk46CisJCQlyZXR1cm4gcGF0Y2hfaW50ZXJuYWwoVk1JX0NBTExfSVJFVCwgbGVuLCBpbnNucyk7CisJCWNhc2UgUEFSQVZJUlRfU1RJX1NZU0VYSVQ6CisJCQlyZXR1cm4gcGF0Y2hfaW50ZXJuYWwoVk1JX0NBTExfU1lTRVhJVCwgbGVuLCBpbnNucyk7CisJCWRlZmF1bHQ6CisJCQlicmVhazsKKwl9CisJcmV0dXJuIGxlbjsKK30KKworLyogQ1BVSUQgaGFzIG5vbi1DIHNlbWFudGljcywgYW5kIHBhcmF2aXJ0LW9wcyBBUEkgZG9lc24ndCBtYXRjaCBoYXJkd2FyZSBJU0EgKi8KK3N0YXRpYyB2b2lkIHZtaV9jcHVpZCh1bnNpZ25lZCBpbnQgKmVheCwgdW5zaWduZWQgaW50ICplYngsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdW5zaWduZWQgaW50ICplY3gsIHVuc2lnbmVkIGludCAqZWR4KQoreworCWludCBvdmVycmlkZSA9IDA7CisJaWYgKCplYXggPT0gMSkKKwkJb3ZlcnJpZGUgPSAxOworICAgICAgICBhc20gdm9sYXRpbGUgKCJjYWxsIColNiIKKyAgICAgICAgICAgICAgICAgICAgICA6ICI9YSIgKCplYXgpLAorICAgICAgICAgICAgICAgICAgICAgICAgIj1iIiAoKmVieCksCisgICAgICAgICAgICAgICAgICAgICAgICAiPWMiICgqZWN4KSwKKyAgICAgICAgICAgICAgICAgICAgICAgICI9ZCIgKCplZHgpCisgICAgICAgICAgICAgICAgICAgICAgOiAiMCIgKCplYXgpLCAiMiIgKCplY3gpLCAiciIgKHZtaV9vcHMuY3B1aWQpKTsKKwlpZiAob3ZlcnJpZGUpIH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BDT05GSUdfTVREX0NGSV9TVEFBIGlzIG5vdCBzZXQKK0NPTkZJR19NVERfQ0ZJX1VUSUw9bQorIyBDT05GSUdfTVREX1JBTSBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfUk9NIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9BQlNFTlQgaXMgbm90IHNldAorIyBDT05GSUdfTVREX09CU09MRVRFX0NISVBTIGlzIG5vdCBzZXQKKworIworIyBNYXBwaW5nIGRyaXZlcnMgZm9yIGNoaXAgYWNjZXNzCisjCisjIENPTkZJR19NVERfQ09NUExFWF9NQVBQSU5HUyBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfUEhZU01BUCBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfUExBVFJBTSBpcyBub3Qgc2V0CisKKyMKKyMgU2VsZi1jb250YWluZWQgTVREIGRldmljZSBkcml2ZXJzCisjCisjIENPTkZJR19NVERfU0xSQU0gaXMgbm90IHNldAorIyBDT05GSUdfTVREX1BIUkFNIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9NVERSQU0gaXMgbm90IHNldAorIyBDT05GSUdfTVREX0JMT0NLMk1URCBpcyBub3Qgc2V0CisKKyMKKyMgRGlzay1Pbi1DaGlwIERldmljZSBEcml2ZXJzCisjCisjIENPTkZJR19NVERfRE9DMjAwMCBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfRE9DMjAwMSBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfRE9DMjAwMVBMVVMgaXMgbm90IHNldAorCisjCisjIE5BTkQgRmxhc2ggRGV2aWNlIERyaXZlcnMKKyMKKyMgQ09ORklHX01URF9OQU5EIGlzIG5vdCBzZXQKKworIworIyBPbmVOQU5EIEZsYXNoIERldmljZSBEcml2ZXJzCisjCisjIENPTkZJR19NVERfT05FTkFORCBpcyBub3Qgc2V0CiAKICMKICMgUGFyYWxsZWwgcG9ydCBzdXBwb3J0CkBAIC0xNTIsNyArMzYwLDYgQEAKICMKICMgQmxvY2sgZGV2aWNlcwogIwotIyBDT05GSUdfQkxLX0RFVl9GRCBpcyBub3Qgc2V0CiAjIENPTkZJR19CTEtfREVWX0NPV19DT01NT04gaXMgbm90IHNldAogQ09ORklHX0JMS19ERVZfTE9PUD15CiAjIENPTkZJR19CTEtfREVWX0NSWVBUT0xPT1AgaXMgbm90IHNldApAQCAtMTYwLDIzICszNjcsMjEgQEAKIENPTkZJR19CTEtfREVWX1JBTT15CiBDT05GSUdfQkxLX0RFVl9SQU1fQ09VTlQ9MTYKIENPTkZJR19CTEtfREVWX1JBTV9TSVpFPTQwOTYKK0NPTkZJR19CTEtfREVWX1JBTV9CTE9DS1NJWkU9MTAyNAogIyBDT05GSUdfQkxLX0RFVl9JTklUUkQgaXMgbm90IHNldAotQ09ORklHX0lOSVRSQU1GU19TT1VSQ0U9IiIKICMgQ09ORklHX0NEUk9NX1BLVENEVkQgaXMgbm90IHNldAorQ09ORklHX0FUQV9PVkVSX0VUSD1tCiAKICMKLSMgSU8gU2NoZWR1bGVycworIyBNaXNjIGRldmljZXMKICMKLUNPTkZJR19JT1NDSEVEX05PT1A9eQotIyBDT05GSUdfSU9TQ0hFRF9BUyBpcyBub3Qgc2V0Ci1DT05GSUdfSU9TQ0hFRF9ERUFETElORT15Ci1DT05GSUdfSU9TQ0hFRF9DRlE9eQotIyBDT05GSUdfQVRBX09WRVJfRVRIIGlzIG5vdCBzZXQKKyMgQ09ORklHX1RJRk1fQ09SRSBpcyBub3Qgc2V0CiAKICMKICMgQVRBL0FUQVBJL01GTS9STEwgc3VwcG9ydAogIwogQ09ORklHX0lERT15CitDT05GSUdfSURFX01BWF9IV0lGUz00CiBDT05GSUdfQkxLX0RFVl9JREU9eQogCiAjCkBAIC0xODUsNyArMzkwLDYgQEAKICMgQ09ORklHX0JMS19ERVZfSURFX1NBVEEgaXMgbm90IHNldAogQ09ORklHX0JMS19ERVZfSURFRElTSz15CiAjIENPTkZJR19JREVESVNLX01VTFRJX01PREUgaXMgbm90IHNldAotQ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MgQ09ORklHX1NFTlNPUlNfU01TQzQ3TTE5MiBpcyBub3Qgc2V0CisjIENPTkZJR19TRU5TT1JTX1NNU0M0N0IzOTcgaXMgbm90IHNldAorIyBDT05GSUdfU0VOU09SU19WVDEyMTEgaXMgbm90IHNldAorQ09ORklHX1NFTlNPUlNfVzgzNzgxRD1tCisjIENPTkZJR19TRU5TT1JTX1c4Mzc5MUQgaXMgbm90IHNldAorIyBDT05GSUdfU0VOU09SU19XODM3OTJEIGlzIG5vdCBzZXQKK0NPTkZJR19TRU5TT1JTX1c4M0w3ODVUUz1tCitDT05GSUdfU0VOU09SU19XODM2MjdIRj1tCisjIENPTkZJR19TRU5TT1JTX1c4MzYyN0VIRiBpcyBub3Qgc2V0CisjIENPTkZJR19IV01PTl9ERUJVR19DSElQIGlzIG5vdCBzZXQKIAogIwogIyBNdWx0aW1lZGlhIGRldmljZXMKICMKLSMgQ09ORklHX1ZJREVPX0RFViBpcyBub3Qgc2V0CitDT05GSUdfVklERU9fREVWPW0KK0NPTkZJR19WSURFT19WNEwxPXkKK0NPTkZJR19WSURFT19WNEwxX0NPTVBBVD15CitDT05GSUdfVklERU9fVjRMMj15CisKKyMKKyMgVmlkZW8gQ2FwdHVyZSBBZGFwdGVycworIworCisjCisjIFZpZGVvIENhcHR1cmUgQWRhcHRlcnMKKyMKKyMgQ09ORklHX1ZJREVPX0FEVl9ERUJVRyBpcyBub3Qgc2V0CitDT05GSUdfVklERU9fSEVMUEVSX0NISVBTX0FVVE89eQorIyBDT05GSUdfVklERU9fVklWSSBpcyBub3Qgc2V0CisjIENPTkZJR19WSURFT19QTVMgaXMgbm90IHNldAorQ09ORklHX1ZJREVPX0JXUUNBTT1tCitDT05GSUdfVklERU9fQ1FDQU09bQorIyBDT05GSUdfVklERU9fVzk5NjYgaXMgbm90IHNldAorIyBDT05GSUdfVklERU9fQ1BJQSBpcyBub3Qgc2V0CisjIENPTkZJR19WSURFT19TQUE1MjQ2QSBpcyBub3Qgc2V0CisjIENP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IyBNZW1vcnkgVGVjaG5vbG9neSBEZXZpY2VzIChNVEQpCiAjCi0jIENPTkZJR19NVEQgaXMgbm90IHNldAorQ09ORklHX01URD15CisjIENPTkZJR19NVERfREVCVUcgaXMgbm90IHNldAorIyBDT05GSUdfTVREX0NPTkNBVCBpcyBub3Qgc2V0CitDT05GSUdfTVREX1BBUlRJVElPTlM9eQorQ09ORklHX01URF9SRURCT09UX1BBUlRTPXkKK0NPTkZJR19NVERfUkVEQk9PVF9ESVJFQ1RPUllfQkxPQ0s9LTEKKyMgQ09ORklHX01URF9SRURCT09UX1BBUlRTX1VOQUxMT0NBVEVEIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9SRURCT09UX1BBUlRTX1JFQURPTkxZIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9DTURMSU5FX1BBUlRTIGlzIG5vdCBzZXQKKworIworIyBVc2VyIE1vZHVsZXMgQW5kIFRyYW5zbGF0aW9uIExheWVycworIworIyBDT05GSUdfTVREX0NIQVIgaXMgbm90IHNldAorQ09ORklHX01URF9CTE9DSz15CisjIENPTkZJR19GVEwgaXMgbm90IHNldAorIyBDT05GSUdfTkZUTCBpcyBub3Qgc2V0CisjIENPTkZJR19JTkZUTCBpcyBub3Qgc2V0CisjIENPTkZJR19SRkRfRlRMIGlzIG5vdCBzZXQKKyMgQ09ORklHX1NTRkRDIGlzIG5vdCBzZXQKKworIworIyBSQU0vUk9NL0ZsYXNoIGNoaXAgZHJpdmVycworIworQ09ORklHX01URF9DRkk9bQorQ09ORklHX01URF9KRURFQ1BST0JFPW0KK0NPTkZJR19NVERfR0VOX1BST0JFPW0KK0NPTkZJR19NVERfQ0ZJX0FEVl9PUFRJT05TPXkKKyMgQ09ORklHX01URF9DRklfTk9TV0FQIGlzIG5vdCBzZXQKK0NPTkZJR19NVERfQ0ZJX0JFX0JZVEVfU1dBUD15CisjIENPTkZJR19NVERfQ0ZJX0xFX0JZVEVfU1dBUCBpcyBub3Qgc2V0CitDT05GSUdfTVREX0NGSV9HRU9NRVRSWT15CitDT05GSUdfTVREX01BUF9CQU5LX1dJRFRIXzE9eQorQ09ORklHX01URF9NQVBfQkFOS19XSURUSF8yPXkKK0NPTkZJR19NVERfTUFQX0JBTktfV0lEVEhfND15CisjIENPTkZJR19NVERfTUFQX0JBTktfV0lEVEhfOCBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfTUFQX0JBTktfV0lEVEhfMTYgaXMgbm90IHNldAorIyBDT05GSUdfTVREX01BUF9CQU5LX1dJRFRIXzMyIGlzIG5vdCBzZXQKK0NPTkZJR19NVERfQ0ZJX0kxPXkKKyMgQ09ORklHX01URF9DRklfSTIgaXMgbm90IHNldAorIyBDT05GSUdfTVREX0NGSV9JNCBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfQ0ZJX0k4IGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9PVFAgaXMgbm90IHNldAorIyBDT05GSUdfTVREX0NGSV9JTlRFTEVYVCBpcyBub3Qgc2V0CitDT05GSUdfTVREX0NGSV9BTURTVEQ9bQorIyBDT05GSUdfTVREX0NGSV9TVEFBIGlzIG5vdCBzZXQKK0NPTkZJR19NVERfQ0ZJX1VUSUw9bQorIyBDT05GSUdfTVREX1JBTSBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfUk9NIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9BQlNFTlQgaXMgbm90IHNldAorIyBDT05GSUdfTVREX09CU09MRVRFX0NISVBTIGlzIG5vdCBzZXQKKworIworIyBNYXBwaW5nIGRyaXZlcnMgZm9yIGNoaXAgYWNjZXNzCisjCisjIENPTkZJR19NVERfQ09NUExFWF9NQVBQSU5HUyBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfUEhZU01BUCBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfUExBVFJBTSBpcyBub3Qgc2V0CisKKyMKKyMgU2VsZi1jb250YWluZWQgTVREIGRldmljZSBkcml2ZXJzCisjCisjIENPTkZJR19NVERfU0xSQU0gaXMgbm90IHNldAorIyBDT05GSUdfTVREX1BIUkFNIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9NVERSQU0gaXMgbm90IHNldAorIyBDT05GSUdfTVREX0JMT0NLMk1URCBpcyBub3Qgc2V0CisKKyMKKyMgRGlzay1Pbi1DaGlwIERldmljZSBEcml2ZXJzCisjCisjIENPTkZJR19NVERfRE9DMjAwMCBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfRE9DMjAwMSBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfRE9DMjAwMVBMVVMgaXMgbm90IHNldAorCisjCisjIE5BTkQgRmxhc2ggRGV2aWNlIERyaXZlcnMKKyMKKyMgQ09ORklHX01URF9OQU5EIGlzIG5vdCBzZXQKKworIworIyBPbmVOQU5EIEZsYXNoIERldmljZSBEcml2ZXJzCisjCisjIENPTkZJR19NVERfT05FTkFORCBpcyBub3Qgc2V0CiAKICMKICMgUGFyYWxsZWwgcG9ydCBzdXBwb3J0CkBAIC0xNTYsNyArMzYwLDYgQEAKICMKICMgQmxvY2sgZGV2aWNlcwogIwotIyBDT05GSUdfQkxLX0RFVl9GRCBpcyBub3Qgc2V0CiAjIENPTkZJR19CTEtfREVWX0NPV19DT01NT04gaXMgbm90IHNldAogQ09ORklHX0JMS19ERVZfTE9PUD15CiAjIENPTkZJR19CTEtfREVWX0NSWVBUT0xPT1AgaXMgbm90IHNldApAQCAtMTY0LDIzICszNjcsMjEgQEAKIENPTkZJR19CTEtfREVWX1JBTT15CiBDT05GSUdfQkxLX0RFVl9SQU1fQ09VTlQ9MTYKIENPTkZJR19CTEtfREVWX1JBTV9TSVpFPTQwOTYKK0NPTkZJR19CTEtfREVWX1JBTV9CTE9DS1NJWkU9MTAyNAogIyBDT05GSUdfQkxLX0RFVl9JTklUUkQgaXMgbm90IHNldAotQ09ORklHX0lOSVRSQU1GU19TT1VSQ0U9IiIKICMgQ09ORklHX0NEUk9NX1BLVENEVkQgaXMgbm90IHNldAorQ09ORklH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IGlzIG5vdCBzZXQKKyMgQ09ORklHX05GVEwgaXMgbm90IHNldAorIyBDT05GSUdfSU5GVEwgaXMgbm90IHNldAorIyBDT05GSUdfUkZEX0ZUTCBpcyBub3Qgc2V0CisjIENPTkZJR19TU0ZEQyBpcyBub3Qgc2V0CisKKyMKKyMgUkFNL1JPTS9GbGFzaCBjaGlwIGRyaXZlcnMKKyMKK0NPTkZJR19NVERfQ0ZJPW0KK0NPTkZJR19NVERfSkVERUNQUk9CRT1tCitDT05GSUdfTVREX0dFTl9QUk9CRT1tCitDT05GSUdfTVREX0NGSV9BRFZfT1BUSU9OUz15CisjIENPTkZJR19NVERfQ0ZJX05PU1dBUCBpcyBub3Qgc2V0CitDT05GSUdfTVREX0NGSV9CRV9CWVRFX1NXQVA9eQorIyBDT05GSUdfTVREX0NGSV9MRV9CWVRFX1NXQVAgaXMgbm90IHNldAorQ09ORklHX01URF9DRklfR0VPTUVUUlk9eQorQ09ORklHX01URF9NQVBfQkFOS19XSURUSF8xPXkKK0NPTkZJR19NVERfTUFQX0JBTktfV0lEVEhfMj15CitDT05GSUdfTVREX01BUF9CQU5LX1dJRFRIXzQ9eQorIyBDT05GSUdfTVREX01BUF9CQU5LX1dJRFRIXzggaXMgbm90IHNldAorIyBDT05GSUdfTVREX01BUF9CQU5LX1dJRFRIXzE2IGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9NQVBfQkFOS19XSURUSF8zMiBpcyBub3Qgc2V0CitDT05GSUdfTVREX0NGSV9JMT15CisjIENPTkZJR19NVERfQ0ZJX0kyIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9DRklfSTQgaXMgbm90IHNldAorIyBDT05GSUdfTVREX0NGSV9JOCBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfT1RQIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9DRklfSU5URUxFWFQgaXMgbm90IHNldAorQ09ORklHX01URF9DRklfQU1EU1REPW0KKyMgQ09ORklHX01URF9DRklfU1RBQSBpcyBub3Qgc2V0CitDT05GSUdfTVREX0NGSV9VVElMPW0KKyMgQ09ORklHX01URF9SQU0gaXMgbm90IHNldAorIyBDT05GSUdfTVREX1JPTSBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfQUJTRU5UIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9PQlNPTEVURV9DSElQUyBpcyBub3Qgc2V0CisKKyMKKyMgTWFwcGluZyBkcml2ZXJzIGZvciBjaGlwIGFjY2VzcworIworIyBDT05GSUdfTVREX0NPTVBMRVhfTUFQUElOR1MgaXMgbm90IHNldAorIyBDT05GSUdfTVREX1BIWVNNQVAgaXMgbm90IHNldAorIyBDT05GSUdfTVREX1BMQVRSQU0gaXMgbm90IHNldAorCisjCisjIFNlbGYtY29udGFpbmVkIE1URCBkZXZpY2UgZHJpdmVycworIworIyBDT05GSUdfTVREX1NMUkFNIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9QSFJBTSBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfTVREUkFNIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9CTE9DSzJNVEQgaXMgbm90IHNldAorCisjCisjIERpc2stT24tQ2hpcCBEZXZpY2UgRHJpdmVycworIworIyBDT05GSUdfTVREX0RPQzIwMDAgaXMgbm90IHNldAorIyBDT05GSUdfTVREX0RPQzIwMDEgaXMgbm90IHNldAorIyBDT05GSUdfTVREX0RPQzIwMDFQTFVTIGlzIG5vdCBzZXQKKworIworIyBOQU5EIEZsYXNoIERldmljZSBEcml2ZXJzCisjCisjIENPTkZJR19NVERfTkFORCBpcyBub3Qgc2V0CisKKyMKKyMgT25lTkFORCBGbGFzaCBEZXZpY2UgRHJpdmVycworIworIyBDT05GSUdfTVREX09ORU5BTkQgaXMgbm90IHNldAogCiAjCiAjIFBhcmFsbGVsIHBvcnQgc3VwcG9ydApAQCAtMTUyLDcgKzM1Nyw2IEBACiAjCiAjIEJsb2NrIGRldmljZXMKICMKLSMgQ09ORklHX0JMS19ERVZ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MgUkFNL1JPTS9GbGFzaCBjaGlwIGRyaXZlcnMKQEAgLTE4Niw2ICszMTcsNyBAQAogIyBNYXBwaW5nIGRyaXZlcnMgZm9yIGNoaXAgYWNjZXNzCiAjCiAjIENPTkZJR19NVERfQ09NUExFWF9NQVBQSU5HUyBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfUExBVFJBTSBpcyBub3Qgc2V0CiAKICMKICMgU2VsZi1jb250YWluZWQgTVREIGRldmljZSBkcml2ZXJzCkBAIC0xOTMsNyArMzI1LDYgQEAKICMgQ09ORklHX01URF9TTFJBTSBpcyBub3Qgc2V0CiAjIENPTkZJR19NVERfUEhSQU0gaXMgbm90IHNldAogIyBDT05GSUdfTVREX01URFJBTSBpcyBub3Qgc2V0Ci0jIENPTkZJR19NVERfQkxLTVREIGlzIG5vdCBzZXQKICMgQ09ORklHX01URF9CTE9DSzJNVEQgaXMgbm90IHNldAogCiAjCkBAIC0yMDksNiArMzQwLDExIEBACiAjIENPTkZJR19NVERfTkFORCBpcyBub3Qgc2V0CiAKICMKKyMgT25lTkFORCBGbGFzaCBEZXZpY2UgRHJpdmVycworIworIyBDT05GSUdfTVREX09ORU5BTkQgaXMgbm90IHNldAorCisjCiAjIFBhcmFsbGVsIHBvcnQgc3VwcG9ydAogIwogIyBDT05GSUdfUEFSUE9SVCBpcyBub3Qgc2V0CkBAIC0yMjAsNyArMzU2LDYgQEAKICMKICMgQmxvY2sgZGV2aWNlcwogIwotIyBDT05GSUdfQkxLX0RFVl9GRCBpcyBub3Qgc2V0CiAjIENPTkZJR19CTEtfREVWX0NPV19DT01NT04gaXMgbm90IHNldAogQ09ORklHX0JMS19ERVZfTE9PUD15CiAjIENPTkZJR19CTEtfREVWX0NSWVBUT0xPT1AgaXMgbm90IHNldApAQCAtMjI4LDIzICszNjMsMjEgQEAKIENPTkZJR19CTEtfREVWX1JBTT15CiBDT05GSUdfQkxLX0RFVl9SQU1fQ09VTlQ9MTYKIENPTkZJR19CTEtfREVWX1JBT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ORklHX1NZU19IWVBFUlZJU09SIGlzIG5vdCBzZXQKKworIworIyBDb25uZWN0b3IgLSB1bmlmaWVkIHVzZXJzcGFjZSA8LT4ga2VybmVsc3BhY2UgbGlua2VyCisjCisjIENPTkZJR19DT05ORUNUT1IgaXMgbm90IHNldAogCiAjCiAjIE1lbW9yeSBUZWNobm9sb2d5IERldmljZXMgKE1URCkKQEAgLTE1Niw2ICsyODcsOCBAQAogIyBDT05GSUdfRlRMIGlzIG5vdCBzZXQKICMgQ09ORklHX05GVEwgaXMgbm90IHNldAogIyBDT05GSUdfSU5GVEwgaXMgbm90IHNldAorIyBDT05GSUdfUkZEX0ZUTCBpcyBub3Qgc2V0CisjIENPTkZJR19TU0ZEQyBpcyBub3Qgc2V0CiAKICMKICMgUkFNL1JPTS9GbGFzaCBjaGlwIGRyaXZlcnMKQEAgLTE4MSw2ICszMTQsNyBAQAogIyBNYXBwaW5nIGRyaXZlcnMgZm9yIGNoaXAgYWNjZXNzCiAjCiAjIENPTkZJR19NVERfQ09NUExFWF9NQVBQSU5HUyBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfUExBVFJBTSBpcyBub3Qgc2V0CiAKICMKICMgU2VsZi1jb250YWluZWQgTVREIGRldmljZSBkcml2ZXJzCkBAIC0xODgsNyArMzIyLDYgQEAKICMgQ09ORklHX01URF9TTFJBTSBpcyBub3Qgc2V0CiAjIENPTkZJR19NVERfUEhSQU0gaXMgbm90IHNldAogIyBDT05GSUdfTVREX01URFJBTSBpcyBub3Qgc2V0Ci0jIENPTkZJR19NVERfQkxLTVREIGlzIG5vdCBzZXQKICMgQ09ORklHX01URF9CTE9DSzJNVEQgaXMgbm90IHNldAogCiAjCkBAIC0yMDQsNiArMzM3LDExIEBACiAjIENPTkZJR19NVERfTkFORCBpcyBub3Qgc2V0CiAKICMKKyMgT25lTkFORCBGbGFzaCBEZXZpY2UgRHJpdmVycworIworIyBDT05GSUdfTVREX09ORU5BTkQgaXMgbm90IHNldAorCisjCiAjIF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U0kgZGlzayBzdXBwb3J0JworIwogCiAjCiAjIFVTQiBHYWRnZXQgU3VwcG9ydApAQCAtNTQyLDMwICs2NDksNzMgQEAKICMgQ09ORklHX01NQyBpcyBub3Qgc2V0CiAKICMKKyMgTEVEIGRldmljZXMKKyMKKyMgQ09ORklHX05FV19MRURTIGlzIG5vdCBzZXQKKworIworIyBMRUQgZHJpdmVycworIworCisjCisjIExFRCBUcmlnZ2VycworIworCisjCiAjIEluZmluaUJhbmQgc3VwcG9ydAogIwotIyBDT05GSUdfSU5GSU5JQkFORCBpcyBub3Qgc2V0CisKKyMKKyMgRURBQyAtIGVycm9yIGRldGVjdGlvbiBhbmQgcmVwb3J0aW5nIChSQVMpIChFWFBFUklNRU5UQUwpCisjCisKKyMKKyMgUmVhbCBUaW1lIENsb2NrCisjCisjIENPTkZJR19SVENfQ0xBU1MgaXMgbm90IHNldAorCisjCisjIERNQSBFbmdpbmUgc3VwcG9ydAorIworIyBDT05GSUdfRE1BX0VOR0lORSBpcyBub3Qgc2V0CisKKyMKKyMgRE1BIENsaWVudHMKKyMKKworIworIyBETUEgRGV2aWNlcworIwogCiAjCiAjIEZpbGUgc3lzdGVtcwogIwogQ09ORklHX0VYVDJfRlM9eQogIyBDT05GSUdfRVhUMl9GU19YQVRUUiBpcyBub3Qgc2V0Ci0jIENPTkZJR19FWFQzX0ZTIGlzIG5vdCBzZXQKLSMgQ09ORklHX0pCRCBpcyBub3Qgc2V0CisjIENPTkZJR19FWFQyX0ZTX1hJUCBpcyBub3Qgc2V0CitDT05GSUdfRVhUM19GUz15CitDT05GSUdfRVhUM19GU19YQVRUUj15CisjIENPTkZJR19FWFQzX0ZTX1BPU0lYX0FDTCBpcyBub3Qgc2V0CisjIENPTkZJR19FWFQzX0ZTX1NFQ1VSSVRZIGlzIG5vdCBzZXQKKyMgQ09ORklHX0VYVDRERVZfRlMgaXMgbm90IHNldAorQ09ORklHX0pCRD15CisjIENPTkZJR19KQkRfREVCVUcgaXMgbm90IHNldA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FUklDX0NBTElCUkFURV9ERUxBWT15CitDT05GSUdfUFJFRU1QVD15CisjIENPTkZJR19TTVAgaXMgbm90IHNldAorQ09ORklHX05PREVTX1NISUZUPTEKKworIworIyBCdXMgb3B0aW9ucyAoUENJLCBQQ01DSUEsIEVJU0EsIE1DQSwgSVNBKQorIworIyBDT05GSUdfSVNBIGlzIG5vdCBzZXQKKworIworIyBQQ0NBUkQgKFBDTUNJQS9DYXJkQnVzKSBzdXBwb3J0CisjCitDT05GSUdfUENDQVJEPXkKKyMgQ09ORklHX1BDTUNJQV9ERUJVRyBpcyBub3Qgc2V0CitDT05GSUdfUENNQ0lBPXkKK0NPTkZJR19QQ01DSUFfTE9BRF9DSVM9eQorQ09ORklHX1BDTUNJQV9JT0NUTD15CisKKyMKKyMgUEMtY2FyZCBicmlkZ2VzCisjCisjIENPTkZJR19NMzJSX0NGQyBpcyBub3Qgc2V0CisKKyMKKyMgUENJIEhvdHBsdWcgU3VwcG9ydAorIworCisjCisjIEV4ZWN1dGFibGUgZmlsZSBmb3JtYXRzCisjCitDT05GSUdfQklORk1UX0VMRj15CisjIENPTkZJR19CSU5GTVRfTUlTQyBpcyBub3Qgc2V0CisKKyMKKyMgTmV0d29ya2luZworIworQ09ORklHX05FVD15CisKKyMKKyMgTmV0d29ya2luZyBvcHRpb25zCisjCisjIENPTkZJR19ORVRERUJVRyBpcyBub3Qgc2V0CitDT05GSUdfUEFDS0VUPXkKKyMgQ09ORklHX1BBQ0tFVF9NTUFQIGlzIG5vdCBzZXQKK0NPTkZJR19VTklYPXkKK0NPTkZJR19YRlJNPXkKKyMgQ09ORklHX1hGUk1fVVNFUiBpcyBub3Qgc2V0CisjIENPTkZJR19YRlJNX1NVQl9QT0xJQ1kgaXMgbm90IHNldAorIyBDT05GSUdfTkVUX0tFWSBpcyBub3Qgc2V0CitDT05GSUdfSU5FVD15CisjIENPTkZJR19JUF9NVUxUSUNBU1QgaXMgbm90IHNldAorIyBDT05GSUdfSVBfQURWQU5DRUR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BHZW5lcmljIERyaXZlciBPcHRpb25zCisjCitDT05GSUdfU1RBTkRBTE9ORT15CitDT05GSUdfUFJFVkVOVF9GSVJNV0FSRV9CVUlMRD15CitDT05GSUdfRldfTE9BREVSPXkKKyMgQ09ORklHX1NZU19IWVBFUlZJU09SIGlzIG5vdCBzZXQKKworIworIyBDb25uZWN0b3IgLSB1bmlmaWVkIHVzZXJzcGFjZSA8LT4ga2VybmVsc3BhY2UgbGlua2VyCisjCisjIENPTkZJR19DT05ORUNUT1IgaXMgbm90IHNldAorCisjCisjIE1lbW9yeSBUZWNobm9sb2d5IERldmljZXMgKE1URCkKKyMKKyMgQ09ORklHX01URCBpcyBub3Qgc2V0CisKKyMKKyMgUGFyYWxsZWwgcG9ydCBzdXBwb3J0CisjCisjIENPTkZJR19QQVJQT1JUIGlzIG5vdCBzZXQKKworIworIyBQbHVnIGFuZCBQbGF5IHN1cHBvcnQKKyMKKworIworIyBCbG9jayBkZXZpY2VzCisjCisjIENPTkZJR19CTEtfREVWX0NPV19DT01NT04gaXMgbm90IHNldAorQ09ORklHX0JMS19ERVZfTE9PUD15CisjIENPTkZJR19CTEtfREVWX0NSWVBUT0xPT1AgaXMgbm90IHNldAorQ09ORklHX0JMS19ERVZfTkJEPXkKK0NPTkZJR19CTEtfREVWX1JBTT15CitDT05GSUdfQkxLX0RFVl9SQU1fQ09VTlQ9MTYKK0NPTkZJR19CTEtfREVWX1JBTV9TSVpFPTQwOTYKK0NPTkZJR19CTEtfREVWX1JBTV9CTE9DS1NJWkU9MTAyNAorIyBDT05GSUdfQkxLX0RFVl9JTklUUkQgaXMgbm90IHNldAorIyBDT05GSUdfQ0RST01fUEtUQ0RWRCBpcyBub3Qgc2V0CisjIENPTkZJR19BVEFfT1ZFUl9FVEggaXMgbm90IHNldAorCisjCisjIE1pc2MgZGV2aWNlcworIworIyBDT05GSUdfVElGTV9DT1JFIGlzIG5vdCBzZXQKKworIworIyBBVEEvQVRBUEkvTUZNL1JMTCBzdXBwb3J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CcKKyMKKworIworIyBVU0IgR2FkZ2V0IFN1cHBvcnQKKyMKKyMgQ09ORklHX1VTQl9HQURHRVQgaXMgbm90IHNldAorCisjCisjIE1NQy9TRCBDYXJkIHN1cHBvcnQKKyMKKyMgQ09ORklHX01NQyBpcyBub3Qgc2V0CisKKyMKKyMgTEVEIGRldmljZXMKKyMKKyMgQ09ORklHX05FV19MRURTIGlzIG5vdCBzZXQKKworIworIyBMRUQgZHJpdmVycworIworCisjCisjIExFRCBUcmlnZ2VycworIworCisjCisjIEluZmluaUJhbmQgc3VwcG9ydAorIworCisjCisjIEVEQUMgLSBlcnJvciBkZXRlY3Rpb24gYW5kIHJlcG9ydGluZyAoUkFTKSAoRVhQRVJJTUVOVEFMKQorIworCisjCisjIFJlYWwgVGltZSBDbG9jaworIworIyBDT05GSUdfUlRDX0NMQVNTIGlzIG5vdCBzZXQKKworIworIyBETUEgRW5naW5lIHN1cHBvcnQKKyMKKyMgQ09ORklHX0RNQV9FTkdJTkUgaXMgbm90IHNldAorCisjCisjIERNQSBDbGllbnRzCisjCisKKyMKKyMgRE1BIERldmljZXMKKyMKKworIworIyBGaWxlIHN5c3RlbXMKKyMKK0NPTkZJR19FWFQyX0ZTPXkKKyMgQ09ORklHX0VYVDJfRlNfWEFUVFIgaXMgbm90IHNldAorIyBDT05GSUdfRVhUMl9GU19YSVAgaXMgbm90IHNldAorQ09ORklHX0VYVDNfRlM9eQorQ09ORklHX0VYVDNfRlNfWEFUVFI9eQorIyBDT05GSUdfRVhUM19GU19QT1NJWF9BQ0wgaXMgbm90IHNldAorIyBDT05GSUdfRVhUM19GU19TRUNVUklUWSBpcyBub3Qgc2V0CisjIENPTkZJR19FWFQ0REVWX0ZTIGlzIG5vdCBzZXQKK0NPTkZJR19KQkQ9eQorQ09ORklHX0pCRF9ERUJVRz15CitDT05GSUdfRlNfTUJDQUNIRT15CisjIENPTkZJR19SRUlTRVJGU19GUyBpcyBub3Qgc2V0CisjIENPTkZJR19KRlNfRlMgaX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nQKICMKLSMgQ09ORklHX0lORklOSUJBTkQgaXMgbm90IHNldAorCisjCisjIEVEQUMgLSBlcnJvciBkZXRlY3Rpb24gYW5kIHJlcG9ydGluZyAoUkFTKSAoRVhQRVJJTUVOVEFMKQorIworCisjCisjIFJlYWwgVGltZSBDbG9jaworIworIyBDT05GSUdfUlRDX0NMQVNTIGlzIG5vdCBzZXQKKworIworIyBETUEgRW5naW5lIHN1cHBvcnQKKyMKKyMgQ09ORklHX0RNQV9FTkdJTkUgaXMgbm90IHNldAorCisjCisjIERNQSBDbGllbnRzCisjCisKKyMKKyMgRE1BIERldmljZXMKKyMKIAogIwogIyBGaWxlIHN5c3RlbXMKICMKIENPTkZJR19FWFQyX0ZTPXkKICMgQ09ORklHX0VYVDJfRlNfWEFUVFIgaXMgbm90IHNldAotQ09ORklHX0VYVDNfRlM9bQorIyBDT05GSUdfRVhUMl9GU19YSVAgaXMgbm90IHNldAorQ09ORklHX0VYVDNfRlM9eQogQ09ORklHX0VYVDNfRlNfWEFUVFI9eQogIyBDT05GSUdfRVhUM19GU19QT1NJWF9BQ0wgaXMgbm90IHNldAogIyBDT05GSUdfRVhUM19GU19TRUNVUklUWSBpcyBub3Qgc2V0Ci1DT05GSUdfSkJEPW0KKyMgQ09ORklHX0VYVDRERVZfRlMgaXMgbm90IHNldAorQ09ORklHX0pCRD15CiBDT05GSUdfSkJEX0RFQlVHPXkKIENPTkZJR19GU19NQkNBQ0hFPXkKLUNPTkZJR19SRUlTRVJGU19GUz1tCi0jIENPTkZJR19SRUlTRVJGU19DSEVDSyBpcyBub3Qgc2V0Ci0jIENPTkZJR19SRUlTRVJGU19QUk9DX0lORk8gaXMgbm90IHNldAotIyBDT05GSUdfUkVJU0VSRlNfRlNfWEFUVFIgaXMgbm90IHNldAorIyBDT05GSUdfUkVJU0VSRlNfRlMgaXMgbm90IHNldAogIyBDT05GSUdfSkZTX0ZTIGlzIG5vdCBzZXQKLQotIwotIyBYRlMgc3VwcG9ydAotIworIyBDT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yBDT05GSUdfRlRMIGlzIG5vdCBzZXQKKyMgQ09ORklHX05GVEwgaXMgbm90IHNldAorIyBDT05GSUdfSU5GVEwgaXMgbm90IHNldAorIyBDT05GSUdfUkZEX0ZUTCBpcyBub3Qgc2V0CisjIENPTkZJR19TU0ZEQyBpcyBub3Qgc2V0CisKKyMKKyMgUkFNL1JPTS9GbGFzaCBjaGlwIGRyaXZlcnMKKyMKKyMgQ09ORklHX01URF9DRkkgaXMgbm90IHNldAorQ09ORklHX01URF9KRURFQ1BST0JFPXkKK0NPTkZJR19NVERfR0VOX1BST0JFPXkKKyMgQ09ORklHX01URF9DRklfQURWX09QVElPTlMgaXMgbm90IHNldAorQ09ORklHX01URF9NQVBfQkFOS19XSURUSF8xPXkKK0NPTkZJR19NVERfTUFQX0JBTktfV0lEVEhfMj15CitDT05GSUdfTVREX01BUF9CQU5LX1dJRFRIXzQ9eQorIyBDT05GSUdfTVREX01BUF9CQU5LX1dJRFRIXzggaXMgbm90IHNldAorIyBDT05GSUdfTVREX01BUF9CQU5LX1dJRFRIXzE2IGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9NQVBfQkFOS19XSURUSF8zMiBpcyBub3Qgc2V0CitDT05GSUdfTVREX0NGSV9JMT15CitDT05GSUdfTVREX0NGSV9JMj15CisjIENPTkZJR19NVERfQ0ZJX0k0IGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9DRklfSTggaXMgbm90IHNldAorIyBDT05GSUdfTVREX0NGSV9JTlRFTEVYVCBpcyBub3Qgc2V0CitDT05GSUdfTVREX0NGSV9BTURTVEQ9eQorIyBDT05GSUdfTVREX0NGSV9TVEFBIGlzIG5vdCBzZXQKK0NPTkZJR19NVERfQ0ZJX1VUSUw9eQorIyBDT05GSUdfTVREX1JBTSBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfUk9NIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9BQlNFTlQgaXMgbm90IHNldAorIyBDT05GSUdfTVREX09CU09MRVRFX0NISVBTIGlzIG5vdCBzZXQKKworIworIyBNYXBwaW5nIGRyaXZlcnMgZm9yIGNoaXAgYWNjZXNzCisjCisjIENPTkZJR19NVERfQ09NUExFWF9NQVBQSU5HUyBpcyBub3Qgc2V0CitDT05GSUdfTVREX1BIWVNNQVA9eQorQ09ORklHX01URF9QSFlTTUFQX1NUQVJUPTB4MAorQ09ORklHX01URF9QSFlTTUFQX0xFTj0weDAKK0NPTkZJR19NVERfUEhZU01BUF9CQU5LV0lEVEg9MAorIyBDT05GSUdfTVREX1BMQVRSQU0gaXMgbm90IHNldAorCisjCisjIFNlbGYtY29udGFpbmVkIE1URCBkZXZpY2UgZHJpdmVycworIworIyBDT05GSUdfTVREX1BNQzU1MSBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfU0xSQU0gaXMgbm90IHNldAorIyBDT05GSUdfTVREX1BIUkFNIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9NVERSQU0gaXMgbm90IHNldAorIyBDT05GSUdfTVREX0JMT0NLMk1URCBpcyBub3Qgc2V0CisKKyMKKyMgRGlzay1Pbi1DaGlwIERldmljZSBEcml2ZXJzCisjCisjIENPTkZJR19NVERfRE9DMjAwMCBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfRE9DMjAwMSBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfRE9DMjAwMVBMVVMgaXMgbm90IHNldAorCisjCisjIE5BTkQgRmxhc2ggRGV2aWNlIERyaXZlcnMKKyMKKyMgQ09ORklHX01URF9OQU5EIGlzIG5vdCBzZXQKKworIworIyBPbmVOQU5EIEZsYXNoIERldmljZSBEcml2ZXJzCisjCisjIENPTkZJR19NVERfT05FTkFORCBpcyBub3Qgc2V0CiAKICMKICMgUGFyYWxsZWwgcG9ydCBzdXBwb3J0CkBAIC0zNTgsNiArNDYzLDcgQEAKICMKICMgUGx1ZyBhbmQgUGxheSBzdXBwb3J0CiAjCisjIENPTkZJR19QTlBBQ1BJIGlzIG5vdCBzZXQKIAogIwog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FWFRfQklUPXkKIENPTkZJR19HRU5FUklDX0hXRUlHSFQ9eQogQ09ORklHX0dFTkVSSUNfQ0FMSUJSQVRFX0RFTEFZPXkKK0NPTkZJR19HRU5FUklDX1RJTUU9eQogQ09ORklHX1NDSEVEX05PX05PX09NSVRfRlJBTUVfUE9JTlRFUj15CisjIENPTkZJR19HRU5FUklDX0hBUkRJUlFTX05PX19ET19JUlEgaXMgbm90IHNldAogQ09ORklHX0RNQV9OT05DT0hFUkVOVD15CiBDT05GSUdfRE1BX05FRURfUENJX01BUF9TVEFURT15CiBDT05GSUdfTUlQU19ESVNBQkxFX09CU09MRVRFX0lERT15CiAjIENPTkZJR19DUFVfQklHX0VORElBTiBpcyBub3Qgc2V0CiBDT05GSUdfQ1BVX0xJVFRMRV9FTkRJQU49eQorQ09ORklHX1NZU19TVVBQT1JUU19BUE1fRU1VTEFUSU9OPXkKIENPTkZJR19TWVNfU1VQUE9SVFNfTElUVExFX0VORElBTj15CiBDT05GSUdfU09DX0FVMTU1MD15CiBDT05GSUdfU09DX0FVMVgwMD15CkBAIC0xMTcsOCArMTIyLDggQEAKICMgQ09ORklHX1BBR0VfU0laRV82NEtCIGlzIG5vdCBzZXQKIENPTkZJR19DUFVfSEFTX1BSRUZFVENIPXkKIENPTkZJR19NSVBTX01UX0RJU0FCTEVEPXkKLSMgQ09ORklHX01JUFNfTVRfU01UQyBpcyBub3Qgc2V0CiAjIENPTkZJR19NSVBTX01UX1NNUCBpcyBub3Qgc2V0CisjIENPTkZJR19NSVBTX01UX1NNVEMgaXMgbm90IHNldAogIyBDT05GSUdfTUlQU19WUEVfTE9BREVSIGlzIG5vdCBzZXQKIENPTkZJR182NEJJVF9QSFlTX0FERFI9eQogQ09ORklHX0NQVV9IQVNfTExTQz15CkBAIC0xMzUsNyArMTQwLDggQEAKIENPTkZJR19GTEFUX05PREVfTUVNX01BUD15CiAjIENPTkZJR19TUEFSU0VNRU1fU1RBVElDIGlzIG5vdCBzZXQKIENPTkZJR19TU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gKC0tY291bnQgPj0gMCkgeworCQlfX3Jhd193cml0ZXcoKnNyYywgYWRkcik7CisJCXNyYysrOworCX0KK30KKworc3RhdGljIGlubGluZSB2b2lkIG1taW9fb3V0c2wodm9pZCBfX2lvbWVtICphZGRyLCBjb25zdCB1MzIgKnNyYywgaW50IGNvdW50KQoreworCXdoaWxlICgtLWNvdW50ID49IDApIHsKKwkJX19yYXdfd3JpdGVsKCpzcmMsIGFkZHIpOworCQlzcmMrKzsKKwl9Cit9CisKK3ZvaWQgaW9yZWFkOF9yZXAodm9pZCBfX2lvbWVtICphZGRyLCB2b2lkICpkc3QsIHVuc2lnbmVkIGxvbmcgY291bnQpCit7CisJbW1pb19pbnNiKGFkZHIsIGRzdCwgY291bnQpOworfQorCitFWFBPUlRfU1lNQk9MKGlvcmVhZDhfcmVwKTsKKwordm9pZCBpb3JlYWQxNl9yZXAodm9pZCBfX2lvbWVtICphZGRyLCB2b2lkICpkc3QsIHVuc2lnbmVkIGxvbmcgY291bnQpCit7CisJbW1pb19pbnN3KGFkZHIsIGRzdCwgY291bnQpOworfQorCitFWFBPUlRfU1lNQk9MKGlvcmVhZDE2X3JlcCk7CisKK3ZvaWQgaW9yZWFkMzJfcmVwKHZvaWQgX19pb21lbSAqYWRkciwgdm9pZCAqZHN0LCB1bnNpZ25lZCBsb25nIGNvdW50KQoreworCW1taW9faW5zbChhZGRyLCBkc3QsIGNvdW50KTsKK30KKworRVhQT1JUX1NZTUJPTChpb3JlYWQzMl9yZXApOworCit2b2lkIGlvd3JpdGU4X3JlcCh2b2lkIF9faW9tZW0gKmFkZHIsIGNvbnN0IHZvaWQgKnNyYywgdW5zaWduZWQgbG9uZyBjb3VudCkKK3sKKwltbWlvX291dHNiKGFkZHIsIHNyYywgY291bnQpOworfQorCitFWFBPUlRfU1lNQk9MKGlvd3JpdGU4X3JlcCk7CisKK3ZvaWQgaW93cml0ZTE2X3JlcCh2b2lkIF9faW9tZW0gKmFkZHIsIGNvbnN0IHZvaWQgKn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U0pOwogCX0KIH0KIAorc3RhdGljIHZvaWQgX19pbml0IHNuaV9jb25zb2xlX3NldHVwKHZvaWQpCit7CisJY2hhciAqY3R5cGU7CisJY2hhciAqY2RldjsKKwljaGFyICpiYXVkOworCWludCBwb3J0OworCXN0YXRpYyBjaGFyIG9wdGlvbnNbOF07CisKKwljZGV2ID0gcHJvbV9nZXRlbnYgKCJjb25zb2xlX2RldiIpOworCWlmIChzdHJuY21wIChjZGV2LCAidHR5IiwgMykgPT0gMCkgeworCQljdHlwZSA9IHByb21fZ2V0ZW52ICgiY29uc29sZSIpOworCQlzd2l0Y2ggKCpjdHlwZSkgeworCQlkZWZhdWx0OgorCQljYXNlICdsJzoKKwkgICAgICAgICAgICAgICAgcG9ydCA9IDA7CisJICAgICAgICAgICAgICAgIGJhdWQgPSBwcm9tX2dldGVudigibGJhdWQiKTsKKwkgICAgICAgICAgICAgICAgYnJlYWs7CisJCWNhc2UgJ3InOgorCSAgICAgICAgICAgICAgICBwb3J0ID0gMTsKKwkgICAgICAgICAgICAgICAgYmF1ZCA9IHByb21fZ2V0ZW52KCJyYmF1ZCIpOworCSAgICAgICAgICAgICAgICBicmVhazsKKwkJfQorCQlpZiAoYmF1ZCkKKwkJCXN0cmNweShvcHRpb25zLCBiYXVkKTsKKwkJYWRkX3ByZWZlcnJlZF9jb25zb2xlKCJ0dHlTIiwgcG9ydCwgYmF1ZCA/IG9wdGlvbnMgOiBOVUxMKTsKKwl9Cit9CisKIHZvaWQgX19pbml0IHByb21faW5pdCh2b2lkKQogewogCWludCBhcmdjID0gZndfYXJnMDsKIAljaGFyICoqYXJndiA9ICh2b2lkICopZndfYXJnMTsKLQl1bnNpZ25lZCBpbnQgc25pX2JyZF90eXBlID0gKih1bnNpZ25lZCBjaGFyICopIFNOSV9JRFBST01fQlJEVFlQRTsKIAlpbnQgaTsKKwlpbnQgY3B1dHlwZTsKIAotCURCR19QUklOVEYoIkZvdW5kIFNOSSBicmR0eXBlICUwMnhcbiIsIHNuaV9icmRfdHlwZSk7CisJc25pX2JyZF90eXBlID0gKih1bnNpZ25lZCBjaGFyICopU05JX0lEUFJPTV9CUkRUWVBFOworCWNwdXR5cGUgPSAqKHVuc2lnbmVkIGNoYXIgKilTTklfSURQUk9NX0NQVVRZUEU7CisJc3dpdGNoIChzbmlfYnJkX3R5cGUpIHsKKwljYXNlIFNOSV9CUkRfVE9XRVJfT0FTSUM6CisJICAgICAgICBzd2l0Y2ggKGNwdXR5cGUpIHsKKwkJY2FzZSBTTklfQ1BVX004MDMwOgorCQkgICAgICAgIHN5c3R5cGUgPSAiUk00MDAtMzMwIjsKKwkJICAgICAgICBicmVhazsKKwkJY2FzZSBTTklfQ1BVX004MDMxOgorCQkgICAgICAgIHN5c3R5cGUgPSAiUk00MDAtNDMwIjsKKwkJICAgICAgICBicmVhazsKKwkJY2FzZSBTTklfQ1BVX004MDM3OgorCQkgICAgICAgIHN5c3R5cGUgPSAiUk00MDAtNTMwIjsKKwkJICAgICAgICBicmVhazsKKwkJY2FzZSBTTklfQ1BVX004MDM0OgorCQkgICAgICAgIHN5c3R5cGUgPSAiUk00MDAtNzMwIjsKKwkJICAgICAgICBicmVhazsKKwkJZGVmYXVsdDoKKwkJCXN5c3R5cGUgPSAiUk00MDAteHh4IjsKKwkJCWJyZWFrOworCQl9CisJICAgICAgICBicmVhazsKKwljYXNlIFNOSV9CUkRfTUlOSVRPV0VSOgorCSAgICAgICAgc3dpdGNoIChjcHV0eXBlKSB7CisJCWNhc2UgU05JX0NQVV9NODAyMToKKwkJY2FzZSBTTklfQ1BVX004MDQzOgorCQkgICAgICAgIHN5c3R5cGUgPSAiUk00MDAtMTIwIjsKKwkJICAgICAgICBicmVhazsKKwkJY2FzZSBTTklfQ1BVX004MDQwOgorCQkgICAgICAgIHN5c3R5cGUgPSAiUk00MDAtMjIwIjsKKwkJICAgICAgICBicmVhazsKKwkJY2FzZSBTTklfQ1BVX004MDUzOgorCQkgICAgICAgIHN5c3R5cGUgPSAiUk00MDAtMjI1IjsKKwkJICAgICAgICBicmVhazsKKwkJY2FzZSBTTklfQ1BVX004MDUwOgorCQkgICAgICAgIHN5c3R5cGUgPSAiUk00MDAtNDIwIjsKKwkJICAgICAgICBicmVhazsKKwkJZGVmYXVsdDoKKwkJCXN5c3R5cGUgPSAiUk00MDAteHh4IjsKKwkJCWJyZWFrOworCQl9CisJICAgICAgICBicmVhazsKKwljYXNlIFNOSV9CUkRfUENJX1RPV0VSOgorCSAgICAgICAgc3lzdHlwZSA9ICJSTTQwMC1DeHgiOworCSAgICAgICAgYnJlYWs7CisJY2FzZSBTTklfQlJEX1JNMjAwOgorCSAgICAgICAgc3lzdHlwZSA9ICJSTTIwMC14eHgiOworCSAgICAgICAgYnJlYWs7CisJY2FzZSBTTklfQlJEX1BDSV9NVE9XRVI6CisJICAgICAgICBzeXN0eXBlID0gIlJNMzAwLUN4eCI7CisJICAgICAgICBicmVhazsKKwljYXNlIFNOSV9CUkRfUENJX0RFU0tUT1A6CisJICAgICAgICBzd2l0Y2ggKHJlYWRfYzBfcHJpZCgpICYgMHhmZjAwKSB7CisJCWNhc2UgUFJJRF9JTVBfUjQ2MDA6CisJCWNhc2UgUFJJRF9JTVBfUjQ3MDA6CisJCSAgICAgICAgc3lzdHlwZSA9ICJSTTIwMC1DMjAiOworCQkgICAgICAgIGJyZWFrOworCQljYXNlIFBSSURfSU1QX1I1MDAwOgorCQkgICAgICAgIHN5c3R5cGUgPSAiUk0yMDAtQzQwIjsKKwkJICAgICAgICBicmVhazsKKwkJZGVmYXVsdDoKKwkJICAgICAgICBzeXN0eXBlID0gIlJNMjAwLUN4eCI7CisJCSAgICAgICAgYnJlYWs7CisJCX0KKwkgICAgICAgIGJyZWFrOworCWNhc2UgU05JX0JSRF9QQ0lfVE9XRVJfQ1BMVVM6CisJICAgICAgICBzeXN0eXBlID0gIlJNNDAwLUV4eCI7CisJICAgICAgICBicmVhazsKKwljYXNlIFNOSV9CUkRfUENJX01UT1dFUl9DUExVUzoKKwkgIC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PICJDYWxpYnJhdGluZyBzeXN0ZW0gdGltZXIuLi4gIik7CisJZG9zYW1wbGUoKTsJLyogUHJpbWUgY2FjaGUuICovCisJZG9zYW1wbGUoKTsJLyogUHJpbWUgY2FjaGUuICovCisJLyogWmVybyBpcyBOT1QgYW4gb3B0aW9uLiAqLworCWRvIHsKKwkJcjRrX3RpY2tzWzBdID0gZG9zYW1wbGUoKTsKKwl9IHdoaWxlICghcjRrX3RpY2tzWzBdKTsKKwlkbyB7CisJCXI0a190aWNrc1sxXSA9IGRvc2FtcGxlKCk7CisJfSB3aGlsZSAoIXI0a190aWNrc1sxXSk7CisKKwlpZiAocjRrX3RpY2tzWzBdICE9IHI0a190aWNrc1sxXSkgeworCQlwcmludGsoIndhcm5pbmc6IHRpbWVyIGNvdW50cyBkaWZmZXIsIHJldHJ5aW5nLi4uICIpOworCQlyNGtfdGlja3NbMl0gPSBkb3NhbXBsZSgpOworCQlpZiAocjRrX3RpY2tzWzJdID09IHI0a190aWNrc1swXQorCQkgICAgfHwgcjRrX3RpY2tzWzJdID09IHI0a190aWNrc1sxXSkKKwkJCXI0a190aWNrID0gcjRrX3RpY2tzWzJdOworCQllbHNlIHsKKwkJCXByaW50aygiZGlzYWdyZWVtZW50LCB1c2luZyBhdmVyYWdlLi4uICIpOworCQkJcjRrX3RpY2sgPSAocjRrX3RpY2tzWzBdICsgcjRrX3RpY2tzWzFdCisJCQkJICAgKyByNGtfdGlja3NbMl0pIC8gMzsKKwkJfQorCX0gZWxzZQorCQlyNGtfdGljayA9IHI0a190aWNrc1swXTsKKworCXByaW50aygiJWQgWyVkLiUwNGQgTUh6IENQVV1cbiIsIChpbnQpIHI0a190aWNrLAorCQkoaW50KSAocjRrX3RpY2sgLyAoNTAwMDAwIC8gSFopKSwKKwkJKGludCkgKHI0a190aWNrICUgKDUwMDAwMCAvIEhaKSkpOworCisJbWlwc19ocHRfZnJlcXVlbmN5ID0gcjRrX3RpY2sgKiBIWjsKK30KKworLyoKKyAqIFI0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AgMCAgMSAgMCAJLyogUlhfRFYgKi8KKwkJCQkJMCAgMTAgMiAgMCAgMSAgMCAJLyogUlhfRVIgKi8KKwkJCQkJMCAgMCAgMiAgMCAgMSAgMCAJLyogUlhfQ0xLICovCisJCQkJCTIgIDkgIDEgIDAgIDMgIDAgCS8qIEdUWF9DTEsgLSBDTEsxMCAqLworCQkJCQkyICA4ICAyICAwICAxICAwPjsJLyogR1RYMTI1IC0gQ0xLOSAqLworCQkJfTsKKwkJCXBpbzI6IHVjY19waW5AMDIgeworCQkJCXBpby1tYXAgPSA8CisJCQkvKiBwb3J0ICBwaW4gIGRpciAgb3Blbl9kcmFpbiAgYXNzaWdubWVudCAgaGFzX2lycSAqLworCQkJCQkwICAxMSAxICAwICAxICAwICAgLyogVHhEMCAqLworCQkJCQkwICAxMiAxICAwICAxICAwICAgLyogVHhEMSAqLworCQkJCQkwICAxMyAxICAwICAxICAwICAgLyogVHhEMiAqLworCQkJCQkwICAxNCAxICAwICAxICAwICAgLyogVHhEMyAqLworCQkJCQkxICAyICAxICAwICAxICAwICAgLyogVHhENCAqLworCQkJCQkxICAzICAxICAwICAyICAwICAgLyogVHhENSAqLworCQkJCQkxICA1ICAxICAwICAzICAwICAgLyogVHhENiAqLworCQkJCQkxICA4ICAxICAwICAzICAwICAgLyogVHhENyAqLworCQkJCQkwICAxNyAyICAwICAxICAwICAgLyogUnhEMCAqLworCQkJCQkwICAxOCAyICAwICAxICAwICAgLyogUnhEMSAqLworCQkJCQkwICAxOSAyICAwICAxICAwICAgLyogUnhEMiAqLworCQkJCQkwICAxYSAyICAwICAxICAwICAgLyogUnhEMyAqLworCQkJCQkwICAxYiAyICAwICAxICAwICAgLyogUnhENCAqLworCQkJCQkxICBjICAyICAwICAyICAwICAgLyogUnhENSAqLworCQkJCQkxICBkICAyICAwICAzICAwICAgLyogUnhENiAqLworCQkJCQkxICBiICAyICAwICAyICAwICAgLyogUnhENyAqLworCQkJCQkwICAxNSAxICAwICAxICAwICAgLyogVF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yMDA3CisjCisjIENPTkZJR19QUEM2NCBpcyBub3Qgc2V0CitDT05GSUdfUFBDMzI9eQorQ09ORklHX1BQQ19NRVJHRT15CitDT05GSUdfTU1VPXkKK0NPTkZJR19HRU5FUklDX0hBUkRJUlFTPXkKK0NPTkZJR19JUlFfUEVSX0NQVT15CitDT05GSUdfUldTRU1fWENIR0FERF9BTEdPUklUSE09eQorQ09ORklHX0FSQ0hfSEFTX0lMT0cyX1UzMj15CitDT05GSUdfR0VORVJJQ19IV0VJR0hUPXkKK0NPTkZJR19HRU5FUklDX0NBTElCUkFURV9ERUxBWT15CitDT05GSUdfR0VORVJJQ19GSU5EX05FWFRfQklUPXkKK0NPTkZJR19QUEM9eQorQ09ORklHX0VBUkxZX1BSSU5USz15CitDT05GSUdfR0VORVJJQ19OVlJBTT15CitDT05GSUdfU0NIRURfTk9fTk9fT01JVF9GUkFNRV9QT0lOVEVSPXkKK0NPTkZJR19BUkNIX01BWV9IQVZFX1BDX0ZEQz15CitDT05GSUdfUFBDX09GPXkKK0NPTkZJR19QUENfVURCR18xNjU1MD15CisjIENPTkZJR19HRU5FUklDX1RCU1lOQyBpcyBub3Qgc2V0CitDT05GSUdfQVVESVRfQVJDSD15CitDT05GSUdfR0VORVJJQ19CVUc9eQorQ09ORklHX0RFRkFVTFRfVUlNQUdFPXkKKworIworIyBQcm9jZXNzb3Igc3VwcG9ydAorIworIyBDT05GSUdfQ0xBU1NJQzMyIGlzIG5vdCBzZXQKKyMgQ09ORklHX1BQQ184Mnh4IGlzIG5vdCBzZXQKK0NPTkZJR19QUENfODN4eD15CisjIENPTkZJR19QUENfODV4eCBpcyBub3Qgc2V0CisjIENPTkZJR19QUENfODZ4eCBpcyBub3Qgc2V0CisjIENPTkZJR19QUENfOHh4IGlzIG5vdCBzZXQKKyMgQ09ORklHXzQweCBpcyBub3Qgc2V0CisjIENPTkZJR180NHggaXMgbm90IHNldAorIyBDT05GSUdfRTIwMCBpcyBub3Qgc2V0CitDT05GSUdfNn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aW9uIChFWFBFUklNRU5UQUwpCisjCisjIENPTkZJR19USVBDIGlzIG5vdCBzZXQKKyMgQ09ORklHX0FUTSBpcyBub3Qgc2V0CisjIENPTkZJR19CUklER0UgaXMgbm90IHNldAorIyBDT05GSUdfVkxBTl84MDIxUSBpcyBub3Qgc2V0CisjIENPTkZJR19ERUNORVQgaXMgbm90IHNldAorIyBDT05GSUdfTExDMiBpcyBub3Qgc2V0CisjIENPTkZJR19JUFggaXMgbm90IHNldAorIyBDT05GSUdfQVRBTEsgaXMgbm90IHNldAorIyBDT05GSUdfWDI1IGlzIG5vdCBzZXQKKyMgQ09ORklHX0xBUEIgaXMgbm90IHNldAorIyBDT05GSUdfRUNPTkVUIGlzIG5vdCBzZXQKKyMgQ09ORklHX1dBTl9ST1VURVIgaXMgbm90IHNldAorCisjCisjIFFvUyBhbmQvb3IgZmFpciBxdWV1ZWluZworIworIyBDT05GSUdfTkVUX1NDSEVEIGlzIG5vdCBzZXQKKworIworIyBOZXR3b3JrIHRlc3RpbmcKKyMKKyMgQ09ORklHX05FVF9QS1RHRU4gaXMgbm90IHNldAorIyBDT05GSUdfSEFNUkFESU8gaXMgbm90IHNldAorIyBDT05GSUdfSVJEQSBpcyBub3Qgc2V0CisjIENPTkZJR19CVCBpcyBub3Qgc2V0CisjIENPTkZJR19JRUVFODAyMTEgaXMgbm90IHNldAorCisjCisjIERldmljZSBEcml2ZXJzCisjCisKKyMKKyMgR2VuZXJpYyBEcml2ZXIgT3B0aW9ucworIworQ09ORklHX1NUQU5EQUxPTkU9eQorQ09ORklHX1BSRVZFTlRfRklSTVdBUkVfQlVJTEQ9eQorIyBDT05GSUdfRldfTE9BREVSIGlzIG5vdCBzZXQKKyMgQ09ORklHX0RFQlVHX0RSSVZFUiBpcyBub3Qgc2V0CisjIENPTkZJR19TWVNfSFlQRVJWSVNPUiBpcyBub3Qgc2V0CisKKyMKKyMgQ29ubmVjdG9yIC0gdW5pZmllZCB1c2Vyc3BhY2UgPC0+IGtlcm5lbHNwYWNlIGxpbmtlcgorIworIyBDT05GSUdfQ09OTkVDVE9SIGlzIG5vdCBzZXQKKworIworIyBNZW1vcnkgVGVjaG5vbG9neSBEZXZpY2VzIChNVEQpCisjCitDT05GSUdfTVREPXkKKyMgQ09ORklHX01URF9ERUJVRyBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfQ09OQ0FUIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9QQVJUSVRJT05TIGlzIG5vdCBzZXQKKworIworIyBVc2VyIE1vZHVsZXMgQW5kIFRyYW5zbGF0aW9uIExheWVycworIworQ09ORklHX01URF9DSEFSPXkKKyMgQ09ORklHX01URF9CTEtERVZTIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9CTE9DSyBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfQkxPQ0tfUk8gaXMgbm90IHNldAorIyBDT05GSUdfRlRMIGlzIG5vdCBzZXQKKyMgQ09ORklHX05GVEwgaXMgbm90IHNldAorIyBDT05GSUdfSU5GVEwgaXMgbm90IHNldAorIyBDT05GSUdfUkZEX0ZUTCBpcyBub3Qgc2V0CisjIENPTkZJR19TU0ZEQyBpcyBub3Qgc2V0CisKKyMKKyMgUkFNL1JPTS9GbGFzaCBjaGlwIGRyaXZlcnMKKyMKK0NPTkZJR19NVERfQ0ZJPXkKKyMgQ09ORklHX01URF9KRURFQ1BST0JFIGlzIG5vdCBzZXQKK0NPTkZJR19NVERfR0VOX1BST0JFPXkKKyMgQ09ORklHX01URF9DRklfQURWX09QVElPTlMgaXMgbm90IHNldAorQ09ORklHX01URF9NQVBfQkFOS19XSURUSF8xPXkKK0NPTkZJR19NVERfTUFQX0JBTktfV0lEVEhfMj15CitDT05GSUdfTVREX01BUF9CQU5LX1dJRFRIXzQ9eQorIyBDT05GSUdfTVREX01BUF9CQU5LX1dJRFRIXzggaXMgbm90IHNldAorIyBDT05GSUdfTVREX01BUF9CQU5LX1dJRFRIXzE2IGlzIG5vdCBzZXQKKyMgQ09OR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fTUFTVEVSPXkKKworIworIyBTUEkgTWFzdGVyIENvbnRyb2xsZXIgRHJpdmVycworIworQ09ORklHX1NQSV9CSVRCQU5HPXkKK0NPTkZJR19TUElfTVBDODN4eD15CisKKyMKKyMgU1BJIFByb3RvY29sIE1hc3RlcnMKKyMKKworIworIyBEYWxsYXMncyAxLXdpcmUgYnVzCisjCisjIENPTkZJR19XMSBpcyBub3Qgc2V0CisKKyMKKyMgSGFyZHdhcmUgTW9uaXRvcmluZyBzdXBwb3J0CisjCitDT05GSUdfSFdNT049eQorIyBDT05GSUdfSFdNT05fVklEIGlzIG5vdCBzZXQKKyMgQ09ORklHX1NFTlNPUlNfQUJJVFVHVVJVIGlzIG5vdCBzZXQKKyMgQ09ORklHX1NFTlNPUlNfQURNMTAyMSBpcyBub3Qgc2V0CisjIENPTkZJR19TRU5TT1JTX0FETTEwMjUgaXMgbm90IHNldAorIyBDT05GSUdfU0VOU09SU19BRE0xMDI2IGlzIG5vdCBzZXQKKyMgQ09ORklHX1NFTlNPUlNfQURNMTAzMSBpcyBub3Qgc2V0CisjIENPTkZJR19TRU5TT1JTX0FETTkyNDAgaXMgbm90IHNldAorIyBDT05GSUdfU0VOU09SU19BU0IxMDAgaXMgbm90IHNldAorIyBDT05GSUdfU0VOU09SU19BVFhQMSBpcyBub3Qgc2V0CisjIENPTkZJR19TRU5TT1JTX0RTMTYyMSBpcyBub3Qgc2V0CisjIENPTkZJR19TRU5TT1JTX0Y3MTgwNUYgaXMgbm90IHNldAorIyBDT05GSUdfU0VOU09SU19GU0NIRVIgaXMgbm90IHNldAorIyBDT05GSUdfU0VOU09SU19GU0NQT1MgaXMgbm90IHNldAorIyBDT05GSUdfU0VOU09SU19HTDUxOFNNIGlzIG5vdCBzZXQKKyMgQ09ORklHX1NFTlNPUlNfR0w1MjBTTSBpcyBub3Qgc2V0CisjIENPTkZJR19TRU5TT1JTX0lUODcgaXMgbm90IHNldAorIyBDT05GSUdfU0VOU09SU19MTTYzIGlzIG5vdC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ENPTkZJR19JUFggaXMgbm90IHNldAorIyBDT05GSUdfQVRBTEsgaXMgbm90IHNldAorIyBDT05GSUdfWDI1IGlzIG5vdCBzZXQKKyMgQ09ORklHX0xBUEIgaXMgbm90IHNldAorIyBDT05GSUdfRUNPTkVUIGlzIG5vdCBzZXQKKyMgQ09ORklHX1dBTl9ST1VURVIgaXMgbm90IHNldAorCisjCisjIFFvUyBhbmQvb3IgZmFpciBxdWV1ZWluZworIworIyBDT05GSUdfTkVUX1NDSEVEIGlzIG5vdCBzZXQKKworIworIyBOZXR3b3JrIHRlc3RpbmcKKyMKKyMgQ09ORklHX05FVF9QS1RHRU4gaXMgbm90IHNldAorIyBDT05GSUdfSEFNUkFESU8gaXMgbm90IHNldAorIyBDT05GSUdfSVJEQSBpcyBub3Qgc2V0CisjIENPTkZJR19CVCBpcyBub3Qgc2V0CisjIENPTkZJR19JRUVFODAyMTEgaXMgbm90IHNldAorCisjCisjIERldmljZSBEcml2ZXJzCisjCisKKyMKKyMgR2VuZXJpYyBEcml2ZXIgT3B0aW9ucworIworQ09ORklHX1NUQU5EQUxPTkU9eQorQ09ORklHX1BSRVZFTlRfRklSTVdBUkVfQlVJTEQ9eQorIyBDT05GSUdfRldfTE9BREVSIGlzIG5vdCBzZXQKKyMgQ09ORklHX1NZU19IWVBFUlZJU09SIGlzIG5vdCBzZXQKKworIworIyBDb25uZWN0b3IgLSB1bmlmaWVkIHVzZXJzcGFjZSA8LT4ga2VybmVsc3BhY2UgbGlua2VyCisjCisjIENPTkZJR19DT05ORUNUT1IgaXMgbm90IHNldAorCisjCisjIE1lbW9yeSBUZWNobm9sb2d5IERldmljZXMgKE1URCkKKyMKK0NPTkZJR19NVEQ9eQorIyBDT05GSUdfTVREX0RFQlVHIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9DT05DQVQgaXMgbm90IHNldAorIyBDT05GSUdfTVREX1BBUlRJVElPTlMgaXMgbm90IHNldAorCisjCisjIFVzZXIgTW9kdWxlcyBBbmQg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XMgbm90IHNldAorQ09ORklHX01URF9DRklfVVRJTD15CisjIENPTkZJR19NVERfUkFNIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9ST00gaXMgbm90IHNldAorIyBDT05GSUdfTVREX0FCU0VOVCBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfT0JTT0xFVEVfQ0hJUFMgaXMgbm90IHNldAorCisjCisjIE1hcHBpbmcgZHJpdmVycyBmb3IgY2hpcCBhY2Nlc3MKKyMKKyMgQ09ORklHX01URF9DT01QTEVYX01BUFBJTkdTIGlzIG5vdCBzZXQKK0NPTkZJR19NVERfUEhZU01BUD15CitDT05GSUdfTVREX1BIWVNNQVBfU1RBUlQ9MHhmZTAwMDAwMAorQ09ORklHX01URF9QSFlTTUFQX0xFTj0weDgwMDAwMAorQ09ORklHX01URF9QSFlTTUFQX0JBTktXSURUSD0yCisjIENPTkZJR19NVERfUEhZU01BUF9PRiBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfUExBVFJBTSBpcyBub3Qgc2V0CisKKyMKKyMgU2VsZi1jb250YWluZWQgTVREIGRldmljZSBkcml2ZXJzCisjCisjIENPTkZJR19NVERfUE1DNTUxIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9EQVRBRkxBU0ggaXMgbm90IHNldAorIyBDT05GSUdfTVREX00yNVA4MCBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfU0xSQU0gaXMgbm90IHNldAorIyBDT05GSUdfTVREX1BIUkFNIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9NVERSQU0gaXMgbm90IHNldAorIyBDT05GSUdfTVREX0JMT0NLMk1URCBpcyBub3Qgc2V0CisKKyMKKyMgRGlzay1Pbi1DaGlwIERldmljZSBEcml2ZXJzCisjCisjIENPTkZJR19NVERfRE9DMjAwMCBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfRE9DMjAwMSBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfRE9DMjAwMVBMVVMgaXMgbm90IHNldAorCis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XQKKworIworIyBJRUVFIDEzOTQgKEZpcmVXaXJlKSBzdXBwb3J0CisjCisjIENPTkZJR19JRUVFMTM5NCBpcyBub3Qgc2V0CisKKyMKKyMgSTJPIGRldmljZSBzdXBwb3J0CisjCisjIENPTkZJR19JMk8gaXMgbm90IHNldAorCisjCisjIE1hY2ludG9zaCBkZXZpY2UgZHJpdmVycworIworIyBDT05GSUdfTUFDX0VNVU1PVVNFQlROIGlzIG5vdCBzZXQKKyMgQ09ORklHX1dJTkRGQVJNIGlzIG5vdCBzZXQKKworIworIyBOZXR3b3JrIGRldmljZSBzdXBwb3J0CisjCitDT05GSUdfTkVUREVWSUNFUz15CisjIENPTkZJR19EVU1NWSBpcyBub3Qgc2V0CisjIENPTkZJR19CT05ESU5HIGlzIG5vdCBzZXQKKyMgQ09ORklHX0VRVUFMSVpFUiBpcyBub3Qgc2V0CisjIENPTkZJR19UVU4gaXMgbm90IHNldAorCisjCisjIEFSQ25ldCBkZXZpY2VzCisjCisjIENPTkZJR19BUkNORVQgaXMgbm90IHNldAorCisjCisjIFBIWSBkZXZpY2Ugc3VwcG9ydAorIworQ09ORklHX1BIWUxJQj15CisKKyMKKyMgTUlJIFBIWSBkZXZpY2UgZHJpdmVycworIworIyBDT05GSUdfTUFSVkVMTF9QSFkgaXMgbm90IHNldAorIyBDT05GSUdfREFWSUNPTV9QSFkgaXMgbm90IHNldAorIyBDT05GSUdfUVNFTUlfUEhZIGlzIG5vdCBzZXQKKyMgQ09ORklHX0xYVF9QSFkgaXMgbm90IHNldAorQ09ORklHX0NJQ0FEQV9QSFk9eQorIyBDT05GSUdfVklURVNTRV9QSFkgaXMgbm90IHNldAorIyBDT05GSUdfU01TQ19QSFkgaXMgbm90IHNldAorIyBDT05GSUdfQlJPQURDT01fUEhZIGlzIG5vdCBzZXQKKyMgQ09ORklHX0ZJWEVEX1BIWSBpcyBub3Qgc2V0CisKKyMKKyMgRXRoZXJuZXQgKDEwIG9yIDEwME1iaXQpCisjCisjIENPTkZJR19ORVRfRVRIRVJORVQgaXMgbm90IHNldAorCisjCisjIEV0aGVybmV0ICgxMDAwIE1iaXQpCisjCisjIENPTkZJR19BQ0VOSUMgaXMgbm90IHNldAorIyBDT05GSUdfREwySyBpcyBub3Qgc2V0CisjIENPTkZJR19FMTAwMCBpcyBub3Qgc2V0CisjIENPTkZJR19OUzgzODIwIGlzIG5vdCBzZXQKKyMgQ09ORklHX0hBTUFDSEkgaXMgbm90IHNldAorIyBDT05GSUdfWUVMTE9XRklOIGlzIG5vdCBzZXQKKyMgQ09ORklHX1I4MTY5IGlzIG5vdCBzZXQKKyMgQ09ORklHX1NJUzE5MCBpcyBub3Qgc2V0CisjIENPTkZJR19TS0dFIGlzIG5vdCBzZXQKKyMgQ09ORklHX1NLWTIgaXMgbm90IHNldAorIyBDT05GSUdfU0s5OExJTiBpcyBub3Qgc2V0CisjIENPTkZJR19USUdPTjMgaXMgbm90IHNldAorIyBDT05GSUdfQk5YMiBpcyBub3Qgc2V0CitDT05GSUdfR0lBTkZBUj15CitDT05GSUdfR0ZBUl9OQVBJPXkKKyMgQ09ORklHX1FMQTNYWFggaXMgbm90IHNldAorCisjCisjIEV0aGVybmV0ICgxMDAwMCBNYml0KQorIworIyBDT05GSUdfQ0hFTFNJT19UMSBpcyBub3Qgc2V0CisjIENPTkZJR19JWEdCIGlzIG5vdCBzZXQKKyMgQ09ORklHX1MySU8gaXMgbm90IHNldAorIyBDT05GSUdfTVlSSTEwR0UgaXMgbm90IHNldAorIyBDT05GSUdfTkVUWEVOX05JQyBpcyBub3Qgc2V0CisKKyMKKyMgVG9rZW4gUmluZyBkZXZpY2VzCisjCisjIENPTkZJR19UUiBpcyBub3Qgc2V0CisKKyMKKyMgV2lyZWxlc3MgTEFOIChub24taGFtcmFkaW8pCisjCisjIENPTkZJR19ORVRfUkFESU8gaXMgbm90IHNldAorCisjCisjIFdhbiBpbnRlcmZhY2VzCisjCisjIENPTkZJR19XQU4gaXMgbm90IHNldAorIyBDT05GSUdfRkRESSBpcyBub3Qgc2V0CisjIENPTkZJR19ISVBQSSBpcyBub3Qgc2V0CisjIENPTkZJR19QUFAgaXMgbm90IHNldAorIyBDT05GSUdfU0xJUCBpcyBub3Qgc2V0CisjIENPTkZJR19ORVRfRkMgaXMgbm90IHNldAorIyBDT05GSUdfU0hBUEVSIGlzIG5vdCBzZXQKKyMgQ09ORklHX05FVENPTlNPTEUgaXMgbm90IHNldAorIyBDT05GSUdfTkVUUE9MTCBpcyBub3Qgc2V0CisjIENPTkZJR19ORVRfUE9MTF9DT05UUk9MTEVSIGlzIG5vdCBzZXQKKworIworIyBJU0ROIHN1YnN5c3RlbQorIworIyBDT05GSUdfSVNETiBpcyBub3Qgc2V0CisKKyMKKyMgVGVsZXBob255IFN1cHBvcnQKKyMKKyMgQ09ORklHX1BIT05FIGlzIG5vdCBzZXQKKworIworIyBJbnB1dCBkZXZpY2Ugc3VwcG9ydAorIworIyBDT05GSUdfSU5QVVQgaXMgbm90IHNldAorCisjCisjIEhhcmR3YXJlIEkvTyBwb3J0cworIworIyBDT05GSUdfU0VSSU8gaXMgbm90IHNldAorIyBDT05GSUdfR0FNRVBPUlQgaXMgbm90IHNldAorCisjCisjIENoYXJhY3RlciBkZXZpY2VzCisjCisjIENPTkZJR19WVCBpcyBub3Qgc2V0CisjIENPTkZJR19TRVJJQUxfTk9OU1RBTkRBUkQgaXMgbm90IHNldAorCisjCisjIFNlcmlhbCBkcml2ZXJzCisjCitDT05GSUdfU0VSSUFMXzgyNTA9eQorQ09ORklHX1NFUklBTF84MjUwX0NPTlNPTEU9eQorIyBDT05GSUdfU0VSSUFMXzgyNTBfUENJIGlzIG5vdCBzZXQKK0NPTkZJR19TRVJJQUxfODI1MF9OUl9VQVJUUz00CitDT05GSUdfU0VSSUFMXzgyNTBfUlVOVElNRV9VQVJUUz00CisjIENPTkZJR19TRVJJQUxfODI1MF9FWFRFTkRFRCBpcyBub3Qgc2V0CisKKyMKKyMgTm9uLTgyNTAgc2VyaWFsIHBvcnQgc3VwcG9ydAorIworIyBDT05GSUdfU0VSSUFMX1VBUlRMSVRFIGlzIG5vdCBzZXQKK0NPTkZJR19TRVJJQUxfQ09SRT15CitDT05GSUdfU0VSSUFMX0NPUkVfQ09OU09MRT15CisjIENPTkZJR19TRVJJQUxfSlNNIGlzIG5vdCBzZXQKK0NPTkZJR19VTklYOThfUFRZUz15CitDT05GSUdfTEVHQUNZX1BUWVM9eQorQ09ORklHX0xFR0FDWV9QVFlfQ09VTlQ9MjU2CisKKyMKKyMgSVBNSQorIworIyBDT05GSUdfSVBNSV9IQU5ETEVSIGlzIG5vdCBzZXQKKworIworIyBXYXRjaGRvZyBDYXJkcworIworQ09ORklHX1dBVENIRE9HPXkKKyMgQ09ORklHX1dBVENIRE9HX05PV0FZT1VUIGlzIG5vdCBzZXQKKworIworIyBXYXRjaGRvZyBEZXZpY2UgRHJpdmVycworIworIyBDT05GSUdfU09GVF9XQVRDSERPRyBpcyBub3Qgc2V0CitDT05GSUdfODN4eF9XRFQ9eQorCisjCisjIFBDSS1iYXNlZCBXYXRjaGRvZyBDYXJkcworIworIyBDT05GSUdfUENJUENXQVRDSERPRyBpcyBub3Qgc2V0CisjIENPTkZJR19XRFRQQ0kgaXMgbm90IHNldAorQ09ORklHX0hXX1JBTkRPTT15CisjIENPTkZJR19OVlJBTSBpcyBub3Qgc2V0CisjIENPTkZJR19HRU5fUlRDIGlzIG5vdCBzZXQKKyMgQ09ORklHX0RUTEsgaXMgbm90IHNldAorIyBDT05GSUdfUjM5NjQgaXMgbm90IHNldAorIyBDT05GSUdfQVBQTElDT00gaXMgbm90IHNldAorIyBDT05GSUdfQUdQIGlzIG5vdCBzZXQKKyMgQ09ORklHX0RSTSBpcyBub3Qgc2V0CisjIENPTkZJR19SQVdfRFJJVkVSIGlzIG5vdCBzZXQKKworIworIyBUUE0gZGV2aWNlcworIworIyBDT05GSUdfVENHX1RQTSBpcyBub3Qgc2V0CisKKyMKKyMgSTJDIHN1cHBvcnQKKyMK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fSTJDX1ZPT0RPTzMgaXMgbm90IHNldAorIyBDT05GSUdfSTJDX1BDQV9JU0EgaXMgbm90IHNldAorCisjCisjIE1pc2NlbGxhbmVvdXMgSTJDIENoaXAgc3VwcG9ydAorIworIyBDT05GSUdfU0VOU09SU19EUzEzMzcgaXMgbm90IHNldAorIyBDT05GSUdfU0VOU09SU19EUzEzNzQgaXMgbm90IHNldAorIyBDT05GSUdfU0VOU09SU19FRVBST00gaXMgbm90IHNldAorQ09ORklHX1NFTlNPUlNfUENGODU3ND15CisjIENPTkZJR19TRU5TT1JTX1BDQTk1MzkgaXMgbm90IHNldAorIyBDT05GSUdfU0VOU09SU19QQ0Y4NTkxIGlzIG5vdCBzZXQKKyMgQ09ORklHX1NFTlNPUlNfTTQxVDAwIGlzIG5vdCBzZXQKKyMgQ09ORklHX1NFTlNPUlNfTUFYNjg3NSBpcyBub3Qgc2V0CisjIENPTkZJR19JMkNfREVCVUdfQ09SRSBpcyBub3Qgc2V0CisjIENPTkZJR19JMkNfREVCVUdfQUxHTyBpcyBub3Qgc2V0CisjIENPTkZJR19JMkNfREVCVUdfQlVTIGlzIG5vdCBzZXQKKyMgQ09ORklHX0kyQ19ERUJVR19DSElQIGlzIG5vdCBzZXQKKworIworIyBTUEkgc3VwcG9ydAorIworQ09ORklHX1NQST15CitDT05GSUdfU1BJX01BU1RFUj15CisKKyMKKyMgU1BJIE1hc3RlciBDb250cm9sbGVyIERyaXZlcnMKKyMKK0NPTkZJR19TUElfQklUQkFORz15CitDT05GSUdfU1BJX01QQzgzeHg9eQorCisjCisjIFNQSSBQcm90b2NvbCBNYXN0ZXJzCisjCisKKyMKKyMgRGFsbGFzJ3MgMS13aXJlIGJ1cworIworIyBDT05GSUdfVzEgaXMgbm90IHNldAorCisjCisjIEhhcmR3YXJlIE1vbml0b3Jpbmcgc3VwcG9ydAorIworIyBDT05GSUdfSFdNT04gaXMgbm90IHNldAorIyBDT05GSUdfSFdNT05fVklEIGlzIG5vdCBzZXQKKworI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b3J5IgorQ09ORklHX1FVSUNDX0VOR0lORT15CitDT05GSUdfUFBDX0dFTjU1MD15CisjIENPTkZJR19XQU5UX0VBUkxZX1NFUklBTCBpcyBub3Qgc2V0CisKKyMKKyMgUGxhdGZvcm0gc3VwcG9ydAorIworIyBDT05GSUdfTVBDODMxM19SREIgaXMgbm90IHNldAorIyBDT05GSUdfTVBDODMyeF9NRFMgaXMgbm90IHNldAorIyBDT05GSUdfTVBDODM0eF9NRFMgaXMgbm90IHNldAorIyBDT05GSUdfTVBDODM0eF9JVFggaXMgbm90IHNldAorQ09ORklHX01QQzgzNnhfTURTPXkKK0NPTkZJR19QUENfTVBDODM2eD15CisjIENPTkZJR19NUElDIGlzIG5vdCBzZXQKKworIworIyBLZXJuZWwgb3B0aW9ucworIworIyBDT05GSUdfSElHSE1FTSBpcyBub3Qgc2V0CisjIENPTkZJR19IWl8xMDAgaXMgbm90IHNldAorQ09ORklHX0haXzI1MD15CisjIENPTkZJR19IWl8zMDAgaXMgbm90IHNldAorIyBDT05GSUdfSFpfMTAwMCBpcyBub3Qgc2V0CitDT05GSUdfSFo9MjUwCitDT05GSUdfUFJFRU1QVF9OT05FPXkKKyMgQ09ORklHX1BSRUVNUFRfVk9MVU5UQVJZIGlzIG5vdCBzZXQKKyMgQ09ORklHX1BSRUVNUFQgaXMgbm90IHNldAorQ09ORklHX0JJTkZNVF9FTEY9eQorIyBDT05GSUdfQklORk1UX01JU0MgaXMgbm90IHNldAorQ09ORklHX0FSQ0hfRU5BQkxFX01FTU9SWV9IT1RQTFVHPXkKK0NPTkZJR19BUkNIX0ZMQVRNRU1fRU5BQkxFPXkKK0NPTkZJR19BUkNIX1BPUFVMQVRFU19OT0RFX01BUD15CitDT05GSUdfU0VMRUNUX01FTU9SWV9NT0RFTD15CitDT05GSUdfRkxBVE1FTV9NQU5VQUw9eQorIyBDT05GSUdfRElTQ09OVElHTUVNX01BTlVBTCBpcyBub3Qgc2V0CisjIENPTkZJR19TUEFSU0VNRU1fT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lBVVF9UT1VDSFNDUkVFTiBpcyBub3Qgc2V0CisjIENPTkZJR19JTlBVVF9NSVNDIGlzIG5vdCBzZXQKKworIworIyBIYXJkd2FyZSBJL08gcG9ydHMKKyMKKyMgQ09ORklHX1NFUklPIGlzIG5vdCBzZXQKKyMgQ09ORklHX0dBTUVQT1JUIGlzIG5vdCBzZXQKKworIworIyBDaGFyYWN0ZXIgZGV2aWNlcworIworIyBDT05GSUdfVlQgaXMgbm90IHNldAorIyBDT05GSUdfU0VSSUFMX05PTlNUQU5EQVJEIGlzIG5vdCBzZXQKKworIworIyBTZXJpYWwgZHJpdmVycworIworQ09ORklHX1NFUklBTF84MjUwPXkKK0NPTkZJR19TRVJJQUxfODI1MF9DT05TT0xFPXkKK0NPTkZJR19TRVJJQUxfODI1MF9QQ0k9eQorQ09ORklHX1NFUklBTF84MjUwX05SX1VBUlRTPTQKK0NPTkZJR19TRVJJQUxfODI1MF9SVU5USU1FX1VBUlRTPTQKKyMgQ09ORklHX1NFUklBTF84MjUwX0VYVEVOREVEIGlzIG5vdCBzZXQKKworIworIyBOb24tODI1MCBzZXJpYWwgcG9ydCBzdXBwb3J0CisjCisjIENPTkZJR19TRVJJQUxfVUFSVExJVEUgaXMgbm90IHNldAorQ09ORklHX1NFUklBTF9DT1JFPXkKK0NPTkZJR19TRVJJQUxfQ09SRV9DT05TT0xFPXkKKyMgQ09ORklHX1NFUklBTF9KU00gaXMgbm90IHNldAorIyBDT05GSUdfU0VSSUFMX09GX1BMQVRGT1JNIGlzIG5vdCBzZXQKK0NPTkZJR19VTklYOThfUFRZUz15CitDT05GSUdfTEVHQUNZX1BUWVM9eQorQ09ORklHX0xFR0FDWV9QVFlfQ09VTlQ9MjU2CisKKyMKKyMgSVBNSQorIworIyBDT05GSUdfSVBNSV9IQU5ETEVSIGlzIG5vdCBzZXQKKworIworIyBXYXRjaGRvZyBDYXJkcworIworQ09ORklHX1dBVENIRE9HPXkKKyMgQ09ORklHX1dBVENIRE9HX05PV0FZT1VUIGlzIG5vdCBzZXQKKworIworIyBXYXRjaGRvZyBEZXZpY2UgRHJpdmVycworIworIyBDT05GSUdfU09GVF9XQVRDSERPRyBpcyBub3Qgc2V0CitDT05GSUdfODN4eF9XRFQ9eQorCisjCisjIFBDSS1iYXNlZCBXYXRjaGRvZyBDYXJkcworIworIyBDT05GSUdfUENJUENXQVRDSERPRyBpcyBub3Qgc2V0CisjIENPTkZJR19XRFRQQ0kgaXMgbm90IHNldAorQ09ORklHX0hXX1JBTkRPTT15CisjIENPTkZJR19OVlJBTSBpcyBub3Qgc2V0CitDT05GSUdfR0VOX1JUQz15CisjIENPTkZJR19HRU5fUlRDX1ggaXMgbm90IHNldAorIyBDT05GSUdfRFRMSyBpcyBub3Qgc2V0CisjIENPTkZJR19SMzk2NCBpcyBub3Qgc2V0CisjIENPTkZJR19BUFBMSUNPTSBpcyBub3Qgc2V0CisjIENPTkZJR19BR1AgaXMgbm90IHNldAorIyBDT05GSUdfRFJNIGlzIG5vdCBzZXQKKyMgQ09ORklHX1JBV19EUklWRVIgaXMgbm90IHNldAorCisjCisjIFRQTSBkZXZpY2VzCisjCisjIENPTkZJR19UQ0dfVFBNIGlzIG5vdCBzZXQKKworIworIyBJMkMgc3VwcG9ydAorIworQ09ORklHX0kyQz15CitDT05GSUdfSTJDX0NIQVJERVY9eQorCisjCisjIEkyQyBBbGdvcml0aG1zCisjCisjIENPTkZJR19JMkNfQUxHT0JJVCBpcyBub3Qgc2V0CisjIENPTkZJR19JMkNfQUxHT1BDRiBpcyBub3Qgc2V0CisjIENPTkZJR19JMkNfQUxHT1BDQSBpcyBub3Qgc2V0CisKKyMKKyMgSTJDIEhhcmR3YXJlIEJ1cyBzdXBwb3J0CisjCisjIENPTkZJR19JMkNfQUxJMTUzNSBpcyBub3Qgc2V0CisjIENPTkZJR19JMkNfQUxJMTU2MyBpcyBub3Qgc2V0CisjIENPTkZJR19JMkNfQUxJMTVYMyBpcyBub3Qgc2V0CisjIENPTkZJR19JMkNf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ENPTkZJR19TRU5TT1JTX1ZJQTY4NkEgaXMgbm90IHNldAorIyBDT05GSUdfU0VOU09SU19WVDEyMTEgaXMgbm90IHNldAorIyBDT05GSUdfU0VOU09SU19WVDgyMzEgaXMgbm90IHNldAorIyBDT05GSUdfU0VOU09SU19XODM3ODFEIGlzIG5vdCBzZXQKKyMgQ09ORklHX1NFTlNPUlNfVzgzNzkxRCBpcyBub3Qgc2V0CisjIENPTkZJR19TRU5TT1JTX1c4Mzc5MkQgaXMgbm90IHNldAorIyBDT05GSUdfU0VOU09SU19XODM3OTMgaXMgbm90IHNldAorIyBDT05GSUdfU0VOU09SU19XODNMNzg1VFMgaXMgbm90IHNldAorIyBDT05GSUdfU0VOU09SU19XODM2MjdIRiBpcyBub3Qgc2V0CisjIENPTkZJR19TRU5TT1JTX1c4MzYyN0VIRiBpcyBub3Qgc2V0CisjIENPTkZJR19IV01PTl9ERUJVR19DSElQIGlzIG5vdCBzZXQKKworIworIyBNdWx0aW1lZGlhIGRldmljZXMKKyMKKyMgQ09ORklHX1ZJREVPX0RFViBpcyBub3Qgc2V0CisKKyMKKyMgRGlnaXRhbCBWaWRlbyBCcm9hZGNhc3RpbmcgRGV2aWNlcworIworIyBDT05GSUdfRFZCIGlzIG5vdCBzZXQKKworIworIyBHcmFwaGljcyBzdXBwb3J0CisjCitDT05GSUdfRklSTVdBUkVfRURJRD15CisjIENPTkZJR19GQiBpcyBub3Qgc2V0CisjIENPTkZJR19GQl9JQk1fR1hUNDUwMCBpcyBub3Qgc2V0CisjIENPTkZJR19CQUNLTElHSFRfTENEX1NVUFBPUlQgaXMgbm90IHNldAorCisjCisjIFNvdW5kCisjCisjIENPTkZJR19TT1VORCBpcyBub3Qgc2V0CisKKyMKKyMgSElEIERldmljZXMKKyMKK0NPTkZJR19ISUQ9eQorIyBDT05GSUdfSElEX0RFQlVHIGlzIG5vdCBzZXQKKworIworIyBVU0Igc3VwcG9ydAorIworQ09ORklHX1VTQl9BUkNIX0hBU19IQ0Q9eQorQ09ORklHX1VTQl9BUkNIX0hBU19PSENJPXkKK0NPTkZJR19VU0JfQVJDSF9IQVNfRUhDST15CisjIENPTkZJR19VU0IgaXMgbm90IHNldAorCisjCisjIE5PVEU6IFVTQl9TVE9SQUdFIGVuYWJsZXMgU0NTSSwgYW5kICdTQ1NJIGRpc2sgc3VwcG9ydCcKKyMKKworIworIyBVU0IgR2FkZ2V0IFN1cHBvcnQKKyMKKyMgQ09ORklHX1VTQl9HQURHRVQgaXMgbm90IHNldAorCisjCisjIE1NQy9TRCBDYXJkIHN1cHBvcnQKKyMKKyMgQ09ORklHX01NQyBpcyBub3Qgc2V0CisKKyMKKyMgTEVEIGRldmljZXMKKyMKKyMgQ09ORklHX05FV19MRURTIGlzIG5vdCBzZXQKKworIworIyBMRUQgZHJpdmVycworIworCisjCisjIExFRCBUcmlnZ2VycworIworCisjCisjIEluZmluaUJhbmQgc3VwcG9ydAorIworIyBDT05GSUdfSU5GSU5JQkFORCBpcyBub3Qgc2V0CisKKyMKKyMgRURBQyAtIGVycm9yIGRldGVjdGlvbiBhbmQgcmVwb3J0aW5nIChSQVMpIChFWFBFUklNRU5UQUwpCisjCisKKyMKKyMgUmVhbCBUaW1lIENsb2NrCisjCisjIENPTkZJR19SVENfQ0xBU1MgaXMgbm90IHNldAorCisjCisjIERNQSBFbmdpbmUgc3VwcG9ydAorIworIyBDT05GSUdfRE1BX0VOR0lORSBpcyBub3Qgc2V0CisKKyMKKyMgRE1BIENsaWVudHMKKyMKKworIworIyBETUEgRGV2aWNlcworIworCisjCisjIEF1eGlsaWFyeSBEaXNwbGF5IHN1cHBvcnQKKyMKKworIworIyBWaXJ0dWFsaXphdGlvbgorIworCisjCisjIEZpbGUgc3lzdGVtcworIworQ09ORklHX0VYVDJfRlM9eQorIyBDT05GSUdfRVhUMl9GU19YQVRUUiBpcyBub3Qgc2V0CisjIENPTkZJR19FWFQyX0ZTX1hJUCBpcyBub3Qgc2V0CitDT05GSUdfRVhUM19GUz15CitDT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qgc2V0CisKKyMKKyMgVElQQyBDb25maWd1cmF0aW9uIChFWFBFUklNRU5UQUwpCisjCisjIENPTkZJR19USVBDIGlzIG5vdCBzZXQKKyMgQ09ORklHX0FUTSBpcyBub3Qgc2V0CisjIENPTkZJR19CUklER0UgaXMgbm90IHNldAorIyBDT05GSUdfVkxBTl84MDIxUSBpcyBub3Qgc2V0CisjIENPTkZJR19ERUNORVQgaXMgbm90IHNldAorIyBDT05GSUdfTExDMiBpcyBub3Qgc2V0CisjIENPTkZJR19JUFggaXMgbm90IHNldAorIyBDT05GSUdfQVRBTEsgaXMgbm90IHNldAorIyBDT05GSUdfWDI1IGlzIG5vdCBzZXQKKyMgQ09ORklHX0xBUEIgaXMgbm90IHNldAorIyBDT05GSUdfRUNPTkVUIGlzIG5vdCBzZXQKKyMgQ09ORklHX1dBTl9ST1VURVIgaXMgbm90IHNldAorCisjCisjIFFvUyBhbmQvb3IgZmFpciBxdWV1ZWluZworIworIyBDT05GSUdfTkVUX1NDSEVEIGlzIG5vdCBzZXQKKworIworIyBOZXR3b3JrIHRlc3RpbmcKKyMKKyMgQ09ORklHX05FVF9QS1RHRU4gaXMgbm90IHNldAorIyBDT05GSUdfSEFNUkFESU8gaXMgbm90IHNldAorIyBDT05GSUdfSVJEQSBpcyBub3Qgc2V0CisjIENPTkZJR19CVCBpcyBub3Qgc2V0CisjIENPTkZJR19JRUVFODAyMTEgaXMgbm90IHNldAorCisjCisjIERldmljZSBEcml2ZXJzCisjCisKKyMKKyMgR2VuZXJpYyBEcml2ZXIgT3B0aW9ucworIworQ09ORklHX1NUQU5EQUxPTkU9eQorQ09ORklHX1BSRVZFTlRfRklSTVdBUkVfQlVJTEQ9eQorIyBDT05GSUdfRldfTE9BREVSIGlzIG5vdCBzZXQKKyMgQ09ORklHX0RFQlVHX0RSSVZFUiBpcyBub3Qgc2V0CisjIENPTkZJR19ERUJVR19ERVZSRVMgaXMgbm90IHNldAorIyBDT05GSUdfU1lTX0hZUEVSVklTT1Ig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qgc2V0CisjIENPTkZJR19WSVRFU1NFX1BIWSBpcyBub3Qgc2V0CisjIENPTkZJR19TTVNDX1BIWSBpcyBub3Qgc2V0CisjIENPTkZJR19CUk9BRENPTV9QSFkgaXMgbm90IHNldAorIyBDT05GSUdfRklYRURfUEhZIGlzIG5vdCBzZXQKKworIworIyBFdGhlcm5ldCAoMTAgb3IgMTAwTWJpdCkKKyMKK0NPTkZJR19ORVRfRVRIRVJORVQ9eQorQ09ORklHX01JST15CisKKyMKKyMgRXRoZXJuZXQgKDEwMDAgTWJpdCkKKyMKK0NPTkZJR19HSUFORkFSPXkKK0NPTkZJR19HRkFSX05BUEk9eQorCisjCisjIEV0aGVybmV0ICgxMDAwMCBNYml0KQorIworCisjCisjIFRva2VuIFJpbmcgZGV2aWNlcworIworCisjCisjIFdpcmVsZXNzIExBTiAobm9uLWhhbXJhZGlvKQorIworIyBDT05GSUdfTkVUX1JBRElPIGlzIG5vdCBzZXQKKworIworIyBXYW4gaW50ZXJmYWNlcworIworIyBDT05GSUdfV0FOIGlzIG5vdCBzZXQKKyMgQ09ORklHX1BQUCBpcyBub3Qgc2V0CisjIENPTkZJR19TTElQIGlzIG5vdCBzZXQKKyMgQ09ORklHX1NIQVBFUiBpcyBub3Qgc2V0CisjIENPTkZJR19ORVRDT05TT0xFIGlzIG5vdCBzZXQKKyMgQ09ORklHX05FVFBPTEwgaXMgbm90IHNldAorIyBDT05GSUdfTkVUX1BPTExfQ09OVFJPTExFUiBpcyBub3Qgc2V0CisKKyMKKyMgSVNETiBzdWJzeXN0ZW0KKyMKKyMgQ09ORklHX0lTRE4gaXMgbm90IHNldAorCisjCisjIFRlbGVwaG9ueSBTdXBwb3J0CisjCisjIENPTkZJR19QSE9ORSBpcyBub3Qgc2V0CisKKyMKKyMgSW5wdXQgZGV2aWNlIHN1cHBvcnQKKyMKK0NPTkZJR19JTlBVVD15CisjIENPTkZJR19JTlBVVF9GRl9NRU1MRVNTIGlzIG5vdCBzZXQKKworIworIyBVc2VybGFuZCBpbnRlcmZhY2VzCisjCisjIENPTkZJR19JTlBVVF9NT1VTRURFViBpcyBub3Qgc2V0CisjIENPTkZJR19JTlBVVF9KT1lERVYgaXMgbm90IHNldAorIyBDT05GSUdfSU5QVVRfVFNERVYgaXMgbm90IHNldAorIyBDT05GSUdfSU5QVVRfRVZERVYgaXMgbm90IHNldAorIyBDT05GSUdfSU5QVVRfRVZCVUcgaXMgbm90IHNldAorCisjCisjIElucHV0IERldmljZSBEcml2ZXJzCisjCisjIENPTkZJR19JTlBVVF9LRVlCT0FSRCBpcyBub3Qgc2V0CisjIENPTkZJR19JTlBVVF9NT1VTRSBpcyBub3Qgc2V0CisjIENPTkZJR19JTlBVVF9KT1lTVElDSyBpcyBub3Qgc2V0CisjIENPTkZJR19JTlBVVF9UT1VDSFNDUkVFTiBpcyBub3Qgc2V0CisjIENPTkZJR19JTlBVVF9NSVNDIGlzIG5vdCBzZXQKKworIworIyBIYXJkd2FyZSBJL08gcG9ydHMKKyMKKyMgQ09ORklHX1NFUklPIGlzIG5vdCBzZXQKKyMgQ09ORklHX0dBTUVQT1JUIGlzIG5vdCBzZXQKKworIworIyBDaGFyYWN0ZXIgZGV2aWNlcworIworIyBDT05GSUdfVlQgaXMgbm90IHNldAorIyBDT05GSUdfU0VSSUFMX05PTlNUQU5EQVJEIGlzIG5vdCBzZXQKKworIworIyBTZXJpYWwgZHJpdmVycworIworQ09ORklHX1NFUklBTF84MjUwPXkKK0NPTkZJR19TRVJJQUxfODI1MF9DT05TT0xFPXkKK0NPTkZJR19TRVJJQUxfODI1MF9OUl9VQVJUUz00CitDT05GSUdfU0VSSUFMXzgyNTBfUlVOVElNRV9VQVJUUz00CisjIENPTkZJR19TRVJJQUxfODI1MF9FWFRFTkRFRCBpcyBub3Qgc2V0CisKKyMKKyMgTm9uLTgyNTAgc2VyaWFsIHBvcnQgc3VwcG9ydAorIworIyBDT05GSUdfU0VSSUFMX1VBUlRMSVRFIGlzIG5vdCBzZXQKK0NPT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ZJUk1XQVJFX0VESUQ9eQorIyBDT05GSUdfRkIgaXMgbm90IHNldAorIyBDT05GSUdfRkJfSUJNX0dYVDQ1MDAgaXMgbm90IHNldAorIyBDT05GSUdfQkFDS0xJR0hUX0xDRF9TVVBQT1JUIGlzIG5vdCBzZXQKKworIworIyBTb3VuZAorIworIyBDT05GSUdfU09VTkQgaXMgbm90IHNldAorCisjCisjIEhJRCBEZXZpY2VzCisjCitDT05GSUdfSElEPXkKKyMgQ09ORklHX0hJRF9ERUJVRyBpcyBub3Qgc2V0CisKKyMKKyMgVVNCIHN1cHBvcnQKKyMKKyMgQ09ORklHX1VTQl9BUkNIX0hBU19IQ0QgaXMgbm90IHNldAorIyBDT05GSUdfVVNCX0FSQ0hfSEFTX09IQ0kgaXMgbm90IHNldAorIyBDT05GSUdfVVNCX0FSQ0hfSEFTX0VIQ0kgaXMgbm90IHNldAorCisjCisjIE5PVEU6IFVTQl9TVE9SQUdFIGVuYWJsZXMgU0NTSSwgYW5kICdTQ1NJIGRpc2sgc3VwcG9ydCcKKyMKKworIworIyBVU0IgR2FkZ2V0IFN1cHBvcnQKKyMKKyMgQ09ORklHX1VTQl9HQURHRVQgaXMgbm90IHNldAorCisjCisjIE1NQy9TRCBDYXJkIHN1cHBvcnQKKyMKKyMgQ09ORklHX01NQyBpcyBub3Qgc2V0CisKKyMKKyMgTEVEIGRldmljZXMKKyMKKyMgQ09ORklHX05FV19MRURTIGlzIG5vdCBzZXQKKworIworIyBMRUQgZHJpdmVycworIworCisjCisjIExFRCBUcmlnZ2VycworIworCisjCisjIEluZmluaUJhbmQgc3VwcG9ydAorIworCisjCisjIEVEQUMgLSBlcnJvciBkZXRlY3Rpb24gYW5kIHJlcG9ydGluZyAoUkFTKSAoRVhQRVJJTUVOVEFMKQorIworCisjCisjIFJlYWwgVGltZSBDbG9jaworIworIyBDT05GSUdfUlRDX0NMQVNTIGlzIG5vdCBzZXQKKworIworIyBETUEgRW5naW5lIHN1cHBvcnQKKyMKKyMgQ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Mgbm90IHNldAorIyBDT05GSUdfUU5YNEZTX0ZTIGlzIG5vdCBzZXQKKyMgQ09ORklHX1NZU1ZfRlMgaXMgbm90IHNldAorIyBDT05GSUdfVUZTX0ZTIGlzIG5vdCBzZXQKKworIworIyBOZXR3b3JrIEZpbGUgU3lzdGVtcworIworQ09ORklHX05GU19GUz15CitDT05GSUdfTkZTX1YzPXkKKyMgQ09ORklHX05GU19WM19BQ0wgaXMgbm90IHNldAorQ09ORklHX05GU19WND15CisjIENPTkZJR19ORlNfRElSRUNUSU8gaXMgbm90IHNldAorIyBDT05GSUdfTkZTRCBpcyBub3Qgc2V0CitDT05GSUdfUk9PVF9ORlM9eQorQ09ORklHX0xPQ0tEPXkKK0NPTkZJR19MT0NLRF9WND15CitDT05GSUdfTkZTX0NPTU1PTj15CitDT05GSUdfU1VOUlBDPXkKK0NPTkZJR19TVU5SUENfR1NTPXkKK0NPTkZJR19SUENTRUNfR1NTX0tSQjU9eQorIyBDT05GSUdfUlBDU0VDX0dTU19TUEtNMyBpcyBub3Qgc2V0CisjIENPTkZJR19TTUJfRlMgaXMgbm90IHNldAorIyBDT05GSUdfQ0lGUyBpcyBub3Qgc2V0CisjIENPTkZJR19OQ1BfRlMgaXMgbm90IHNldAorIyBDT05GSUdfQ09EQV9GUyBpcyBub3Qgc2V0CisjIENPTkZJR19BRlNfRlMgaXMgbm90IHNldAorIyBDT05GSUdfOVBfRlMgaXMgbm90IHNldAorCisjCisjIFBhcnRpdGlvbiBUeXBlcworIworQ09ORklHX1BBUlRJVElPTl9BRFZBTkNFRD15CisjIENPTkZJR19BQ09STl9QQVJUSVRJT04gaXMgbm90IHNldAorIyBDT05GSUdfT1NGX1BBUlRJVElPTiBpcyBub3Qgc2V0CisjIENPTkZJR19BTUlHQV9QQVJUSVRJT04gaXMgbm90IHNldAorIyBDT05GSUdfQVRBUklfUEFSVElUSU9OIGlzIG5vdCBzZXQKKyMgQ09ORklHX01BQ19QQVJUSVRJT04gaXMgbm90IHNldAor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VybjsKKworCWlwaWNfaW5pdChucCwgMCk7CisKKwkvKiBJbml0aWFsaXplIHRoZSBkZWZhdWx0IGludGVycnVwdCBtYXBwaW5nIHByaW9yaXRpZXMsCisJICogaW4gY2FzZSB0aGUgYm9vdCByb20gY2hhbmdlZCBzb21ldGhpbmcgb24gdXMuCisJICovCisJaXBpY19zZXRfZGVmYXVsdF9wcmlvcml0eSgpOworfQorCisjaWYgZGVmaW5lZChDT05GSUdfSTJDX01QQykgJiYgZGVmaW5lZChDT05GSUdfU0VOU09SU19EUzEzNzQpCitleHRlcm4gdWxvbmcgZHMxMzc0X2dldF9ydGNfdGltZSh2b2lkKTsKK2V4dGVybiBpbnQgZHMxMzc0X3NldF9ydGNfdGltZSh1bG9uZyk7CisKK3N0YXRpYyBpbnQgX19pbml0IG1wYzgzNHhfcnRjX2hvb2t1cCh2b2lkKQoreworCXN0cnVjdCB0aW1lc3BlYyB0djsKKworCWlmICghbWFjaGluZV9pcyhtcGM4MzR4X21kcykpCisJCXJldHVybiAwOworCisJcHBjX21kLmdldF9ydGNfdGltZSA9IGRzMTM3NF9nZXRfcnRjX3RpbWU7CisJcHBjX21kLnNldF9ydGNfdGltZSA9IGRzMTM3NF9zZXRfcnRjX3RpbWU7CisKKwl0di50dl9uc2VjID0gMDsKKwl0di50dl9zZWMgPSAocHBjX21kLmdldF9ydGNfdGltZSkgKCk7CisJZG9fc2V0dGltZW9mZGF5KCZ0dik7CisKKwlyZXR1cm4gMDsKK30KKworbGF0ZV9pbml0Y2FsbChtcGM4MzR4X3J0Y19ob29rdXApOworI2VuZGlmCisKKy8qCisgKiBDYWxsZWQgdmVyeSBlYXJseSwgTU1VIGlzIG9mZiwgZGV2aWNlLXRyZWUgaXNuJ3QgdW5mbGF0dGVuZWQKKyAqLworc3RhdGljIGludCBfX2luaXQgbXBjODM0eF9tZHNfcHJvYmUodm9pZCkKK3sKKyAgICAgICAgdW5zaWduZWQgbG9uZyByb290ID0gb2ZfZ2V0X2ZsYXRfZH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8qIFB1Ymxpc2ggdGhlIFFFIGRldmljZXMgKi8KKwlvZl9wbGF0Zm9ybV9idXNfcHJvYmUoTlVMTCxtcGM4NXh4X2lkcyxOVUxMKTsKKworCXJldHVybiAwOworfQorZGV2aWNlX2luaXRjYWxsKG1wYzg1eHhfcHVibGlzaF9kZXZpY2VzKTsKKworc3RhdGljIHZvaWQgX19pbml0IG1wYzg1eHhfbWRzX3BpY19pbml0KHZvaWQpCit7CisJc3RydWN0IG1waWMgKm1waWM7CisJc3RydWN0IHJlc291cmNlIHI7CisJc3RydWN0IGRldmljZV9ub2RlICpucCA9IE5VTEw7CisKKwlucCA9IG9mX2ZpbmRfbm9kZV9ieV90eXBlKE5VTEwsICJvcGVuLXBpYyIpOworCWlmICghbnApCisJCXJldHVybjsKKworCWlmIChvZl9hZGRyZXNzX3RvX3Jlc291cmNlKG5wLCAwLCAmcikpIHsKKwkJcHJpbnRrKEtFUk5fRVJSICJGYWlsZWQgdG8gbWFwIG1waWMgcmVnaXN0ZXIgc3BhY2VcbiIpOworCQlvZl9ub2RlX3B1dChucCk7CisJCXJldHVybjsKKwl9CisKKwltcGljID0gbXBpY19hbGxvYyhucCwgci5zdGFydCwKKwkJCU1QSUNfUFJJTUFSWSB8IE1QSUNfV0FOVFNfUkVTRVQgfCBNUElDX0JJR19FTkRJQU4sCisJCQk0LCAwLCAiIE9wZW5QSUMgICIpOworCUJVR19PTihtcGljID09IE5VTEwpOworCW9mX25vZGVfcHV0KG5wKTsKKworCS8qIEludGVybmFsIEludGVycnVwdHMgKi8KKwltcGljX2Fzc2lnbl9pc3UobXBpYywgMCwgci5zdGFydCArIDB4MTAyMDApOworCW1waWNfYXNzaWduX2lzdShtcGljLCAxLCByLnN0YXJ0ICsgMHgxMDI4MCk7CisJbXBpY19hc3NpZ25faXN1KG1waWMsIDIsIHIuc3RhcnQgKyAweDEwMzAwKTsKKwltcGljX2Fzc2lnbl9pc3UobXBpYywgMywgci5zdGFydCArIDB4MTAzODApOworCW1waWNfYXNzaWduX2lzdShtcGljLCA0LCByLnN0YXJ0ICsgMHgxMDQwMCk7CisJbXBpY19hc3NpZ25faXN1KG1waWMsIDUsIHIuc3RhcnQgKyAweDEwNDgwKTsKKwltcGljX2Fzc2lnbl9pc3UobXBpYywgNiwgci5zdGFydCArIDB4MTA1MDApOworCW1waWNfYXNzaWduX2lzdShtcGljLCA3LCByLnN0YXJ0ICsgMHgxMDU4MCk7CisJbXBpY19hc3NpZ25faXN1KG1waWMsIDgsIHIuc3RhcnQgKyAweDEwNjAwKTsKKwltcGljX2Fzc2lnbl9pc3UobXBpYywgOSwgci5zdGFydCArIDB4MTA2ODApOworCW1waWNfYXNzaWduX2lzdShtcGljLCAxMCwgci5zdGFydCArIDB4MTA3MDApOworCW1waWNfYXNzaWduX2lzdShtcGljLCAxMSwgci5zdGFydCArIDB4MTA3ODApOworCisJLyogRXh0ZXJuYWwgSW50ZXJydXB0cyAqLworCW1waWNfYXNzaWduX2lzdShtcGljLCAxMiwgci5zdGFydCArIDB4MTAwMDApOworCW1waWNfYXNzaWduX2lzdShtcGljLCAxMywgci5zdGFydCArIDB4MTAwODApOworCW1waWNfYXNzaWduX2lzdShtcGljLCAxNCwgci5zdGFydCArIDB4MTAxMDApOworCisJbXBpY19pbml0KG1waWMpOworCisjaWZkZWYgQ09ORklHX1FVSUNDX0VOR0lORQorCW5wID0gb2ZfZmluZF9ub2RlX2J5X3R5cGUoTlVMTCwgInFlaWMiKTsKKwlpZiAoIW5wKQorCQlyZXR1cm47CisKKwlxZV9pY19pbml0KG5wLCAwKTsKKwlvZl9ub2RlX3B1dChucCk7CisjZW5kaWYJCQkJLyogQ09ORklHX1FVSUNDX0VOR0lORSAqLworfQorCitzdGF0aWMgaW50IF9faW5pdCBtcGM4NXh4X21kc19wcm9iZSh2b2lkKQoreworICAgICAgICB1bnNpZ25lZCBsb25nIHJvb3QgPSBvZl9nZXRfZmxhdF9kdF9yb290KCk7CisKKyAgICAgICAgcmV0dXJuIG9mX2Z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UEIgaXMgbm90IHNldAorIyBDT05GSUdfRUNPTkVUIGlzIG5vdCBzZXQKKyMgQ09ORklHX1dBTl9ST1VURVIgaXMgbm90IHNldAorCisjCisjIFFvUyBhbmQvb3IgZmFpciBxdWV1ZWluZworIworIyBDT05GSUdfTkVUX1NDSEVEIGlzIG5vdCBzZXQKKworIworIyBOZXR3b3JrIHRlc3RpbmcKKyMKKyMgQ09ORklHX05FVF9QS1RHRU4gaXMgbm90IHNldAorIyBDT05GSUdfSEFNUkFESU8gaXMgbm90IHNldAorIyBDT05GSUdfSVJEQSBpcyBub3Qgc2V0CisjIENPTkZJR19CVCBpcyBub3Qgc2V0CisjIENPTkZJR19JRUVFODAyMTEgaXMgbm90IHNldAorCisjCisjIERldmljZSBEcml2ZXJzCisjCisKKyMKKyMgR2VuZXJpYyBEcml2ZXIgT3B0aW9ucworIworIyBDT05GSUdfU1RBTkRBTE9ORSBpcyBub3Qgc2V0CitDT05GSUdfUFJFVkVOVF9GSVJNV0FSRV9CVUlMRD15CisjIENPTkZJR19ERUJVR19EUklWRVIgaXMgbm90IHNldAorIyBDT05GSUdfREVCVUdfREVWUkVTIGlzIG5vdCBzZXQKKyMgQ09ORklHX1NZU19IWVBFUlZJU09SIGlzIG5vdCBzZXQKKworIworIyBDb25uZWN0b3IgLSB1bmlmaWVkIHVzZXJzcGFjZSA8LT4ga2VybmVsc3BhY2UgbGlua2VyCisjCisjIENPTkZJR19DT05ORUNUT1IgaXMgbm90IHNldAorCisjCisjIE1lbW9yeSBUZWNobm9sb2d5IERldmljZXMgKE1URCkKKyMKK0NPTkZJR19NVEQ9eQorIyBDT05GSUdfTVREX0RFQlVHIGlzIG5vdCBzZXQKK0NPTkZJR19NVERfQ09OQ0FUPXkKK0NPTkZJR19NVERfUEFSVElUSU9OUz15CisjIENPTkZJR19NVERfUkVEQk9PVF9QQVJUUyBpcyBub3Qgc2V0CitDT05GSUdfTVREX0NNRExJTkVfUEFSVFM9eQorCisjCisjIFVzZXIgTW9k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ENPTkZJR19NVERfT1RQIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9DRklfSU5URUxFWFQgaXMgbm90IHNldAorQ09ORklHX01URF9DRklfQU1EU1REPXkKKyMgQ09ORklHX01URF9DRklfU1RBQSBpcyBub3Qgc2V0CitDT05GSUdfTVREX0NGSV9VVElMPXkKKyMgQ09ORklHX01URF9SQU0gaXMgbm90IHNldAorIyBDT05GSUdfTVREX1JPTSBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfQUJTRU5UIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9PQlNPTEVURV9DSElQUyBpcyBub3Qgc2V0CisKKyMKKyMgTWFwcGluZyBkcml2ZXJzIGZvciBjaGlwIGFjY2VzcworIworQ09ORklHX01URF9DT01QTEVYX01BUFBJTkdTPXkKK0NPTkZJR19NVERfUEhZU01BUD15CitDT05GSUdfTVREX1BIWVNNQVBfU1RBUlQ9MHg4MDAwMDAwCitDT05GSUdfTVREX1BIWVNNQVBfTEVOPTB4MAorQ09ORklHX01URF9QSFlTTUFQX0JBTktXSURUSD0yCisjIENPTkZJR19NVERfUENJIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9QTEFUUkFNIGlzIG5vdCBzZXQKKworIworIyBTZWxmLWNvbnRhaW5lZCBNVEQgZGV2aWNlIGRyaXZlcnMKKyMKKyMgQ09ORklHX01URF9QTUM1NTEgaXMgbm90IHNldAorIyBDT05GSUdfTVREX1NMUkFNIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9QSFJBTSBpcyBub3Qgc2V0CisjIENPTkZJR19NVERfTVREUkFNIGlzIG5vdCBzZXQKKyMgQ09ORklHX01URF9CTE9DSzJNVEQgaXMgbm90IHNldAorCisjCisjIERpc2stT24tQ2hpcCBEZXZpY2UgRHJpdmVycworIworIyBDT05GSUdfTVREX0RPQzIwMDAgaXMgbm90IHNldAorIyBDT05GSUdfTVREX0RPQzIwMDEgaXMgbm90IHNldAorIyBDT05GSUdfTVREX0RPQzIw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1heSBjYWxsIGl0IGZyb20gYSBib3R0b20gaGFsZi4KKyAqLworaW50IHNtcF9jYWxsX2Z1bmN0aW9uX29uKHZvaWQgKCpmdW5jKSAodm9pZCAqaW5mbyksIHZvaWQgKmluZm8sIGludCBub25hdG9taWMsCisJCQkgIGludCB3YWl0LCBpbnQgY3B1KQoreworCWNwdW1hc2tfdCBtYXAgPSBDUFVfTUFTS19OT05FOworCisJY3B1X3NldChjcHUsIG1hcCk7CisJX19zbXBfY2FsbF9mdW5jdGlvbl9tYXAoZnVuYywgaW5mbywgbm9uYXRvbWljLCB3YWl0LCBtYXApOwogCXJldHVybiAwOwogfQogRVhQT1JUX1NZTUJPTChzbXBfY2FsbF9mdW5jdGlvbl9vbik7CkBAIC0zMjIsMjYgKzMyMCw2IEBACiAJCXVkZWxheSgxMCk7CiB9CiAKLS8qCi0gKiBTZW5kIGFuIGV4dGVybmFsIGNhbGwgc2lncCB0byBldmVyeSBvdGhlciBjcHUgaW4gdGhlIHN5c3RlbSBhbmQKLSAqIHJldHVybiB3aXRob3V0IHdhaXRpbmcgZm9yIGl0cyBjb21wbGV0aW9uLgotICovCi1zdGF0aWMgdm9pZCBzbXBfZXh0X2JpdGNhbGxfb3RoZXJzKGVjX2JpdF9zaWcgc2lnKQotewotICAgICAgICBpbnQgY3B1OwotCi0JZm9yX2VhY2hfb25saW5lX2NwdShjcHUpIHsKLQkJaWYgKGNwdSA9PSBzbXBfcHJvY2Vzc29yX2lkKCkpCi0gICAgICAgICAgICAgICAgICAgICAgICBjb250aW51ZTsKLSAgICAgICAgICAgICAgICAvKgotICAgICAgICAgICAgICAgICAqIFNldCBzaWduYWxpbmcgYml0IGluIGxvd2NvcmUgb2YgdGFyZ2V0IGNwdSBhbmQga2ljayBpdAotICAgICAgICAgICAgICAgICAqLwotCQlzZXRfYml0KHNpZywgKHVuc2lnbmVkIGxvbmcgKikgJmxvd2NvcmVfcHRyW2NwdV0tPmV4dF9jYWxsX2Zhc3QpOwotCQl3aGlsZ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fbDFpcnEodW5zaWduZWQgaW50IGlycSkKLXsKLSAgICAgICAgdW5zaWduZWQgY2hhciBtYXNrOwotICAgICAgICB1bnNpZ25lZCBpbnQgbWFza19wb3J0ID0gKChpcnEgLSBCSUdTVVJfSVJRX0xPVykvOCkgPyBCSUdTVVJfSVJMTVIxIDogQklHU1VSX0lSTE1SMDsKLSAgICAgICAgdW5zaWduZWQgY2hhciBiaXQgPSAgKDEgPDwgKChpcnEgLSBNR0FURV9JUlFfTE9XKSU4KSApOwotCi0gICAgICAgIGlmKGlycSA+PSBCSUdTVVJfSVJRX0xPVyAmJiBpcnEgPCBCSUdTVVJfSVJRX0hJR0gpIHsKLSAgICAgICAgICAgICAgICBwcl9kZWJ1ZygiRGlzYWJsZSBMMSBJUlEgJWRcbiIsIGlycSk7Ci0gICAgICAgICAgICAgICAgRElQUklOVEsoMiwiZGlzYWJsZV9iaWdzdXJfbDFpcnE6IElNUj0weCUwOHggbWFzaz0weCV4XG4iLAotICAgICAgICAgICAgICAgICAgICAgICAgbWFza19wb3J0LCBiaXQpOwotCi0gICAgICAgICAgICAgICAgLyogRGlzYWJsZSBJUlEgLSBzZXQgbWFzayBiaXQgKi8KLSAgICAgICAgICAgICAgICBtYXNrID0gaW5iKG1hc2tfcG9ydCkgfCBiaXQ7Ci0gICAgICAgICAgICAgICAgb3V0YihtYXNrLCBtYXNrX3BvcnQpOwotICAgICAgICAgICAgICAgIHJldHVybjsKLSAgICAgICAgfQotICAgICAgICBwcl9kZWJ1ZygiZGlzYWJsZV9iaWdzdXJfbDFpcnE6IEludmFsaWQgSVJRICVkXG4iLCBpcnEpOwotfQotCi1zdGF0aWMgdm9pZCBlbmFibGVfYmlnc3VyX2wxaXJxKHVuc2lnbmVkIGludCBpcnEpCi17Ci0gICAgICAgIHVuc2lnbmVkIGNoYXIgbWFzazsKLSAgICAgICAgdW5zaWduZWQgaW50IG1hc2tfcG9ydCA9ICgoaXJxIC0gQklHU1VSX0lSUV9MT1cpLzgpID8gQkl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QklHU1VSXzJORExWTF9JUlFfTE9XICYmIGlycSA8IEJJR1NVUl8yTkRMVkxfSVJRX0hJR0gpIHsKLSAgICAgICAgICAgICAgICBwcl9kZWJ1ZygiRW5hYmxlIEwyIElSUSAlZFxuIiwgaXJxKTsKLSAgICAgICAgICAgICAgICBESVBSSU5USygyLCJlbmFibGVfYmlnc3VyX2wyaXJxOiBJTVI9MHglMDh4IG1hc2s9MHgleFxuIiwKLSAgICAgICAgICAgICAgICAgICAgICAgIG1hc2tfcG9ydCwgYml0KTsKLQotICAgICAgICAgICAgICAgIC8qIEVuYWJsZSBMMiBJUlEgLSBjbGVhciBtYXNrIGJpdCAqLwotICAgICAgICAgICAgICAgIG1hc2sgPSBpbmIobWFza19wb3J0KSAmIH5iaXQ7Ci0gICAgICAgICAgICAgICAgb3V0YihtYXNrLCBtYXNrX3BvcnQpOwotICAgICAgICAgICAgICAgIHJldHVybjsKLSAgICAgICAgfQotICAgICAgICBwcl9kZWJ1ZygiZW5hYmxlX2JpZ3N1cl9sMmlycTogSW52YWxpZCBJUlEgJWRcbiIsIGlycSk7Ci19Ci0KLXN0YXRpYyB2b2lkIG1hc2tfYW5kX2Fja19iaWdzdXIodW5zaWduZWQgaW50IGlycSkKLXsKLSAgICAgICAgcHJfZGVidWcoIm1hc2tfYW5kX2Fja19iaWdzdXIgSVJRICVkXG4iLCBpcnEpOwotICAgICAgICBpZihpcnEgPj0gQklHU1VSX0lSUV9MT1cgJiYgaXJxIDwgQklHU1VSX0lSUV9ISUdIKQotICAgICAgICAgICAgICAgIGRpc2FibGVfYmlnc3VyX2wxaXJxKGlycSk7Ci0gICAgICAgIGVsc2UKLSAgICAgICAgICAgICAgICBkaXNhYmxlX2JpZ3N1cl9sMmlycShpcnEpOwotfQotCi1zdGF0aWMgdm9pZCBlbmRfYmlnc3VyX2lycSh1bnNpZ25lZCBpbnQgaXJxKQotewotICAgICAgICBwcl9kZWJ1ZygiZW5kX2JpZ3N1cl9pcnEgSVJRICVkXG4iLCBpcnEpOwotICAgICAgICBpZiAoIShpcnFfZGVzY1tpcnFdLnN0YXR1cyAmIChJUlFfRElTQUJMRUR8SVJRX0lOUFJPR1JFU1MpKSkgewotICAgICAgICAgICAgICAgIGlmKGlycSA+PSBCSUdTVVJfSVJRX0xPVyAmJiBpcnEgPCBCSUdTVVJfSVJRX0hJR0gpCi0gICAgICAgICAgICAgICAgICAgICAgICBlbmFibGVfYmlnc3VyX2wxaXJxKGlycSk7Ci0gICAgICAgICAgICAgICAgZWxzZQotICAgICAgICAgICAgICAgICAgICAgICAgZW5hYmxlX2JpZ3N1cl9sMmlycShpcnEpOwotICAgICAgICB9Ci19Ci0KLXN0YXRpYyB1bnNpZ25lZCBpbnQgc3RhcnR1cF9iaWdzdXJfaXJxKHVuc2lnbmVkIGludCBpcnEpCi17Ci0gICAgICAgIHU4IG1hc2s7Ci0gICAgICAgIHUzMiByZWc7Ci0KLSAgICAgICAgcHJfZGVidWcoInN0YXJ0dXBfYmlnc3VyX2lycSBJUlEgJWRcbiIsIGlycSk7Ci0KLSAgICAgICAgaWYoaXJxID49IEJJR1NVUl9JUlFfTE9XICYmIGlycSA8IEJJR1NVUl9JUlFfSElHSCkgewotICAgICAgICAgICAgICAgIC8qIEVuYWJsZSB0aGUgTDEgSVJRICovCi0gICAgICAgICAgICAgICAgZW5hYmxlX2JpZ3N1cl9sMWlycShpcnEpOwotICAgICAgICAgICAgICAgIC8qIEVuYWJsZSBhbGwgTDIgSVJRcyBpbiB0aGlzIEwxIElSUSAqLwotICAgICAgICAgICAgICAgIG1hc2sgPSB+KGJpZ3N1cl9sMmlycV9tYXNrW2lycS1CSUdTVVJfSVJRX0xPV10pOwotICAgICAgICAgICAgICAgIHJlZyA9IGltcl9iYXNlIC0gYmlnc3VyX2wyaXJxX3JlZ1tpcnEtQklHU1VSX0lSUV9MT1ddICogaW1yX29mZnNldDsKLSAgICAgICAgICAgICAgICBtYXNrICY9IGluYihyZWcpOwotICAgICAgICAgICAgICAgIG91dGIobWFzayxyZWcpOwotICAgICAgICAgICAgICAgIERJUFJJTlRLKDIsInN0YXJ0dXBfYmlnc3VyX2lycTogSU1SPTB4JTA4eCBtYXNrPTB4JXhcbiIscmVnLGluYihyZWcpKTsKLSAgICAgICAgfQotICAgICAgICBlbHNlIHsKLSAgICAgICAgICAgICAgICAvKiBFbmFibGUgdGhlIEwyIElSUSAtIGNsZWFyIG1hc2sgYml0ICovCi0gICAgICAgICAgICAgICAgZW5hYmxlX2JpZ3N1cl9sMmlycShpcnEpOwotICAgICAgICAgICAgICAgIC8qIEVuYWJsZSB0aGUgTDEgYml0IG1hc2tpbmcgdGhpcyBMMiBJUlEgKi8KLSAgICAgICAgICAgICAgICBlbmFibGVfYmlnc3VyX2wxaXJxKGJpZ3N1cl9sMl9sMV9tYXBbaXJxLUJJR1NVUl8yTkRMVkxfSVJRX0xPV10pOwotICAgICAgICAgICAgICAgIERJUFJJTlRLKDIsInN0YXJ0dXBfYmlnc3VyX2lycTogTDE9JWQgTDI9JWRcbiIsCi0gICAgICAgICAgICAgICAgICAgICAgICBiaWdzdXJfbDJfbDFfbWFwW2lycS1CSUdTVVJfMk5ETFZMX0lSUV9MT1ddLGlycSk7Ci0gICAgICAgIH0KLSAgICAgICAgcmV0dXJuIDA7Ci19Ci0KLXN0YXRpYyB2b2lkIHNodXRkb3duX2JpZ3N1cl9pcnEodW5zaWduZWQgaW50IGlycSkKLXsKLSAgICAgICAgcHJfZGVidWcoInNodXRkb3duX2JpZ3N1cl9pcnEgSVJRICVkXG4iLCBpcnEpOwotICAgICAgICBpZihpcnEgPj0gQklHU1VSX0lSUV9MT1cgJiYgaXJxIDwgQklHU1VSX0lSUV9ISUdIKQotICAgICAgICAgICAgICAgIGRpc2FibGVfYmlnc3VyX2wxaXJxKGlycSk7Ci0gICAgICAgIGVsc2UKLSAgICAgICAgICAgICAgICBkaXNhYmxlX2JpZ3N1cl9sMmlycShpcnEpOwotfQotCi0vKiBEZWZpbmUgdGhlIElSUSBzdHJ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PV107Ci0gICAgICAgICAgICAgICAgcmVnX251bSA9IGJpZ3N1cl9sMmlycV9yZWdbaXJxLUJJR1NVUl9JUlFfTE9XXTsKLSAgICAgICAgICAgICAgICAvKiBmaW5kIHRoZSBhY3RpdmUgSVJRJ3MgKFhPUiB3aXRoIGluYWN0aXZlIGxldmVsKSovCi0gICAgICAgICAgICAgICAgYWN0dl9pcnFzID0gaW5iKGlzcl9iYXNlLXJlZ19udW0qaXNyX29mZnNldCkgXgotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGJpZ3N1cl9sMl9pbmFjdHZfc3RhdGVbcmVnX251bV07Ci0gICAgICAgICAgICAgICAgLyogZGVjb2RlIGFjdGl2ZSBJUlEncyAqLwotICAgICAgICAgICAgICAgIGFjdHZfaXJxcyA9IGFjdHZfaXJxcyAmIG1hc2sgJiB+KGluYihpbXJfYmFzZS1yZWdfbnVtKmltcl9vZmZzZXQpKTsKLSAgICAgICAgICAgICAgICAvKiBpZiBORVogdGhlbiB3ZSBoYXZlIGFuIGFjdGl2ZSBMMiBJUlEgKi8KLSAgICAgICAgICAgICAgICBpZihhY3R2X2lycXMpIGRtdXhfaXJxID0gZmZ6KH5hY3R2X2lycXMpICsgcmVnX251bSo4K0JJR1NVUl8yTkRMVkxfSVJRX0xPVzsKLSAgICAgICAgICAgICAgICAvKiBpZiBubyAybmQgbGV2ZWwgSVJRIGFjdGlvbiwgYnV0IGhhcyAxc3QgbGV2ZWwsIHVzZSAxc3QgbGV2ZWwgaGFuZGxlciAqLwotICAgICAgICAgICAgICAgIGlmKCFpcnFfZGVzY1tkbXV4X2lycV0uYWN0aW9uICYmIGlycV9kZXNjW2lycV0uYWN0aW9uKQotICAgICAgICAgICAgICAgICAgICAgICAgZG11eF9pcnEgPSBpcnE7Ci0gICAgICAgICAgICAgICAgRElQUklOVEsoMSwiYmlnc3VyX2lycV9kZW11eDogaXJxPSVkIGRtdXhfaXJxPSVkIG1hc2s9MHglMDR4IHJlZz0lZFxuIiwKLSAgICAgICAgICAgICAgICAgICAgICAgIGlycSwgZG11eF9pcnEsIG1hc2ssIHJlZ19udW0pOwotICAgICAgICB9Ci0jaWZkZWYgQ09ORklHX0hENjQ0NjUKLSAgICAgICAgZG11eF9pcnEgPSBoZDY0NDY1X2lycV9kZW11eChkbXV4X2lycSk7Ci0jZW5kaWYgLyogQ09ORklHX0hENjQ0NjUgKi8KLSAgICAgICAgRElQUklOVEsoMywiYmlnc3VyX2lycV9kZW11eCwgZGVtdXhfaXJxPSVkXG4iLCBkbXV4X2lycSk7Ci0KLSAgICAgICAgcmV0dXJuIGRtdXhfaXJxOwotfQotCi0vKj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09Ki8KLS8vICAgICAgICAgICAgICBCaWcgU3VyIEluaXQgUm91dGluZXMKLS8qPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0qLwotdm9pZCBfX2luaXQgaW5pdF9iaWdzdXJfSVJRKHZvaWQpCi17Ci0gICAgICAgIGludCBpOwotCi0gICAgICAgIGlmICghTUFDSF9CSUdTVVIpIHJldHVybjsKLQotICAgICAgICAvKiBDcmVhdGUgSVNSJ3MgZm9yIEJpZyBTdXIgQ1BMRCBJUlEncyAqLwotICAgICAgICAvKj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09Ki8KLSAgICAgICAgZm9yKGk9QklHU1VSX0lSUV9MT1c7aTxCSUdTVVJfSVJRX0hJR0g7aSsrKQotICAgICAgICAgICAgICAgIG1ha2VfYmlnc3VyX2wxaXNyKGkpOwotCi0gICAgICAgIHByaW50ayhLRVJOX0lORk8gIkJpZyBTdXIgQ1BMRCBMMSBpbnRlcnJ1cHRzICVkIHRvICVkLlxuIiwKLSAgICAgICAgICAgICAgICBCSUdTVVJfSVJRX0xPVyxCSUdTVVJfSVJRX0hJR0g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ZWMzMTA0Lmg+Ci0KLS8qIFRoaXMgaXMgZm9yIGRlYnVnZ2luZyBtb3N0bHk7ICBoZXJlJ3MgdGhlIHRhYmxlIHRoYXQgSSBpbnRlbmQgdG8ga2VlcAotICogaW4gaGVyZToKLSAqCi0gKiAgIGluZGV4ICAgICAgZnVuY3Rpb24gICAgICAgIGJhc2UgYWRkciAgICAgICBwb3dlciAgICAgICAgICAgaW50ZXJydXB0IGJpdAotICogICAgICAgMCAgICAgIHBvd2VyICAgICAgICAgICBiMGVjMDAwMCAgICAgICAgLS0tICAgICAgICAgICAgIDAwMDAwMDAxICh1bnVzZWQpCi0gKiAgICAgICAxICAgICAgaXJxcyAgICAgICAgICAgIGIwZWMxMDAwICAgICAgICAtLS0gICAgICAgICAgICAgMDAwMDAwMDIgKHVudXNlZCkKLSAqICAgICAgIDIgICAgICA/PyAgICAgICAgICAgICAgYjBlYzIwMDAgICAgICAgIGIwZWMwMDA4ICAgICAgICAwMDAwMDAwNAotICogICAgICAgMyAgICAgIFBTMiAoMSkgICAgICAgICBiMGVjMzAwMCAgICAgICAgYjBlYzAwMGMgICAgICAgIDAwMDAwMDA4Ci0gKiAgICAgICA0ICAgICAgUFMyICgyKSAgICAgICAgIGIwZWM0MDAwICAgICAgICBiMGVjMDAxMCAgICAgICAgMDAwMDAwMTAKLSAqICAgICAgIDUgICAgICA/PyAgICAgICAgICAgICAgYjBlYzUwMDAgICAgICAgIGIwZWMwMDE0ICAgICAgICAwMDAwMDAyMAotICogICAgICAgNiAgICAgIEkyQyAgICAgICAgICAgICBiMGVjNjAwMCAgICAgICAgYjBlYzAwMTggICAgICAgIDAwMDAwMDQwCi0gKiAgICAgICA3ICAgICAgc2VyaWFsICgxKSAgICAgIGIwZWM3MDAwICAgICAgICBiMGVjMDAxYyAgICAgICAgMDAwMDAwODAKLSAqICAgICAgIDggICAgICBzZXJpYWwgKDIpICAgICAgYjBlYzgwMDAgICAgICAgIGIwZWMwMDIwICAgICAgICAwMDAwMDEwMA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LCAxIGJpdHMgbWVhbiBub3QgcGVuZGluZyBvciBkaXNhYmxlZC4gIGFsbAotICogSVJRcyBzZWVtIHRvIGJlIGxldmVsLXRyaWdnZXJlZC4KLSAqLwotCi0jZGVmaW5lIEVDMzEwNF9JUlIgKEVDMzEwNF9CQVNFICsgMHgxMDAwKQotI2RlZmluZSBFQzMxMDRfSU1SIChFQzMxMDRfQkFTRSArIDB4MTAwNCkKLSNkZWZpbmUgRUMzMTA0X0lQUiAoRUMzMTA0X0JBU0UgKyAweDEwMDgpCi0KLSNkZWZpbmUgY3RybF9yZWFkbChhZGRyKSAoKih2b2xhdGlsZSB1MzIgKikoYWRkcikpCi0jZGVmaW5lIGN0cmxfd3JpdGVsKGRhdGEsYWRkcikgKCoodm9sYXRpbGUgdTMyICopKGFkZHIpID0gKGRhdGEpKQotI2RlZmluZSBjdHJsX3JlYWRiKGFkZHIpICgqKHZvbGF0aWxlIHU4ICopKGFkZHIpKQotCi1zdGF0aWMgY2hhciAqZWMzMTA0X25hbWUodW5zaWduZWQgaW5kZXgpCi17Ci0gICAgICAgIHN3aXRjaChpbmRleCkgewotICAgICAgICBjYXNlIDA6Ci0gICAgICAgICAgICAgICAgcmV0dXJuICJwb3dlciBtYW5hZ2VtZW50IjsKLSAgICAgICAgY2FzZSAxOgotICAgICAgICAgICAgICAgIHJldHVybiAiaW50ZXJydXB0cyI7Ci0gICAgICAgIGNhc2UgMzoKLSAgICAgICAgICAgICAgICByZXR1cm4gIlBTMiAoMSkiOwotICAgICAgICBjYXNlIDQ6Ci0gICAgICAgICAgICAgICAgcmV0dXJuICJQUzIgKDIpIjsKLSAgICAgICAgY2FzZSA1OgotICAgICAgICAgICAgICAgIHJldHVybiAiSTJDICgxKSI7Ci0gICAgICAgIGNhc2UgNjoKLSAgICAgICAgICAgICAgICByZXR1cm4gIkkyQyAoMikiOwotICAgICAgICBjYXNlIDc6Ci0gICAgICAgICAgICAgICAgcmV0dXJuICJzZXJpYWwgKDEpIjsKLSAgICAgICAgY2FzZSA4OgotICAgICAgICAgICAgICAgIHJldHVybiAic2VyaWFsICgyKSI7Ci0gICAgICAgIGNhc2UgOToKLSAgICAgICAgICAgICAgICByZXR1cm4gInNlcmlhbCAoMykiOwotICAgICAgICBjYXNlIDEwOgotICAgICAgICAgICAgICAgIHJldHVybiAic2VyaWFsICg0KSI7Ci0gICAgICAgIGNhc2UgMTY6Ci0gICAgICAgICAgICAgICAgcmV0dXJuICJwY21jaWEgKDEpIjsKLSAgICAgICAgY2FzZSAxNzoKLSAgICAgICAgICAgICAgICByZXR1cm4gInBjbWNpYSAoMikiOwotICAgICAgICBkZWZhdWx0OiB7Ci0gICAgICAgICAgICAgICAgc3RhdGljIGNoYXIgYnVmWzMyXTsKLQotICAgICAgICAgICAgICAgIHNwcmludGYoYnVmLCAidW5rbm93biAoJWQpIiwgaW5kZXgpOwotCi0gICAgICAgICAgICAgICAgcmV0dXJuIGJ1ZjsKLSAgICAgICAgICAgICAgICB9Ci0gICAgICAgIH0KLX0KLQotaW50IGdldF9wZW5kaW5nX2ludGVycnVwdHMoY2hhciAqYnVmKQotewotICAgICAgICB1MzIgaXByOwotICAgICAgICB1MzIgYml0OwotICAgICAgICBjaGFyICpwID0gYnVmOwotCi0gICAgICAgIHAgKz0gc3ByaW50ZihwLCAicGVuZGluZzogKCIpOwotCi0gICAgICAgIGlwciA9IGN0cmxfaW5sKEVDMzEwNF9JUFIpOwotCi0gICAgICAgIGZvciAoYml0ID0gMTsgYml0IDwgMzI7IGJpdCsrKQotICAgICAgICAgICAgICAgIGlmICghKGlwciAmICgxPDxiaXQpKSkKLSAgICAgICAgICAgICAgICAgICAgICAgIHAgKz0gc3ByaW50ZihwLCAiJXMgIiwgZWMzMTA0X25hbWUoYml0KSk7Ci0KLSAgICAgICAgcCArPSBzcHJpbnRmKHAsICIpXG4iKTsKLQotICAgICAgICByZXR1cm4gcCAtIGJ1ZjsKLX0KLQotc3RhdGljIGlubGluZSB1MzIgZWMzMTA0X2lycTJtY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NjW2lycV0uc3RhdHVzICYgKElSUV9ESVNBQkxFRHxJUlFfSU5QUk9HUkVTUykpKQotICAgICAgICAgICAgICAgIHVubWFza19lYzMxMDRfaXJxKGlycSk7Ci19Ci0KLXN0YXRpYyB1bnNpZ25lZCBpbnQgc3RhcnR1cF9lYzMxMDRfaXJxKHVuc2lnbmVkIGludCBpcnEpCi17Ci0gICAgICAgIHVubWFza19lYzMxMDRfaXJxKGlycSk7Ci0KLSAgICAgICAgcmV0dXJuIDA7Ci19Ci0KLXN0YXRpYyB2b2lkIHNodXRkb3duX2VjMzEwNF9pcnEodW5zaWduZWQgaW50IGlycSkKLXsKLSAgICAgICAgbWFza19lYzMxMDRfaXJxKGlycSk7Ci0KLX0KLQotc3RhdGljIHN0cnVjdCBod19pbnRlcnJ1cHRfdHlwZSBlYzMxMDRfaW50ID0gewotICAgICAgICAudHlwZW5hbWUgICAgICAgPSAiRUMzMTA0IiwKLSAgICAgICAgLmVuYWJsZSAgICAgICAgID0gZW5hYmxlX2VjMzEwNF9pcnEsCi0gICAgICAgIC5kaXNhYmxlICAgICAgICA9IGRpc2FibGVfZWMzMTA0X2lycSwKLSAgICAgICAgLmFjayAgICAgICAgICAgID0gbWFza19hbmRfYWNrX2VjMzEwNF9pcnEsCi0gICAgICAgIC5lbmQgICAgICAgICAgICA9IGVuZF9lYzMxMDRfaXJxLAotICAgICAgICAuc3RhcnR1cCAgICAgICAgPSBzdGFydHVwX2VjMzEwNF9pcnEsCi0gICAgICAgIC5zaHV0ZG93biAgICAgICA9IHNodXRkb3duX2VjMzEwNF9pcnEsCi19OwotCi0vKiBZdWNrLiAgdGhlIF9kZW11eCBBUEkgaXMgdWdseSAqLwotaW50IGVjMzEwNF9pcnFfZGVtdXgoaW50IGlycSkKLXsKLSAgICAgICAgaWYgKGlycSA9PSBFQzMxMDRfSVJRKSB7Ci0gICAgICAgICAgICAgICAgdW5zaWduZWQgaW50IG1hc2s7Ci0KLSAgICAgICAgICAgICAgICBtYXNrID0g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HNlZWsgICAgICAgICA9IG5vX2xsc2VlaywKKwkucmVhZCAgICAgICAgICAgPSBob3N0YXVkaW9fcmVhZCwKKwkud3JpdGUgICAgICAgICAgPSBob3N0YXVkaW9fd3JpdGUsCisJLnBvbGwgICAgICAgICAgID0gaG9zdGF1ZGlvX3BvbGwsCisJLmlvY3RsICAgICAgICAgID0gaG9zdGF1ZGlvX2lvY3RsLAorCS5tbWFwICAgICAgICAgICA9IE5VTEwsCisJLm9wZW4gICAgICAgICAgID0gaG9zdGF1ZGlvX29wZW4sCisJLnJlbGVhc2UgICAgICAgID0gaG9zdGF1ZGlvX3JlbGVhc2UsCiB9OwogCiBzdGF0aWMgY29uc3Qgc3RydWN0IGZpbGVfb3BlcmF0aW9ucyBob3N0bWl4ZXJfZm9wcyA9IHsKLSAgICAgICAgLm93bmVyICAgICAgICAgID0gVEhJU19NT0RVTEUsCi0gICAgICAgIC5sbHNlZWsgICAgICAgICA9IG5vX2xsc2VlaywKLSAgICAgICAgLmlvY3RsICAgICAgICAgID0gaG9zdG1peGVyX2lvY3RsX21peGRldiwKLSAgICAgICAgLm9wZW4gICAgICAgICAgID0gaG9zdG1peGVyX29wZW5fbWl4ZGV2LAotICAgICAgICAucmVsZWFzZSAgICAgICAgPSBob3N0bWl4ZXJfcmVsZWFzZSwKKwkub3duZXIgICAgICAgICAgPSBUSElTX01PRFVMRSwKKwkubGxzZWVrICAgICAgICAgPSBub19sbHNlZWssCisJLmlvY3RsICAgICAgICAgID0gaG9zdG1peGVyX2lvY3RsX21peGRldiwKKwkub3BlbiAgICAgICAgICAgPSBob3N0bWl4ZXJfb3Blbl9taXhkZXYsCisJLnJlbGVhc2UgICAgICAgID0gaG9zdG1peGVyX3JlbGVhc2UsCiB9OwogCiBzdHJ1Y3QgewpAQCAtMzEwLDQyICszMTAsMzEgQEAKIAogc3RhdGljIGludCBfX2luaXQgaG9zdGF1ZGlvX2luaXRfbW9kdWxlKHZvaWQpCiB7Ci0gICAgICAgIHByaW50ayh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HBmbiwgdG90YWwgPSAwLCByZXNlcnZlZCA9IDA7Ci0gICAgICAgIGludCBzaGFyZWQgPSAwLCBjYWNoZWQgPSAwOwotICAgICAgICBpbnQgaGlnaG1lbSA9IDA7CisJaW50IHBmbiwgdG90YWwgPSAwLCByZXNlcnZlZCA9IDA7CisJaW50IHNoYXJlZCA9IDAsIGNhY2hlZCA9IDA7CisJaW50IGhpZ2htZW0gPSAwOwogCXN0cnVjdCBwYWdlICpwYWdlOwogCi0gICAgICAgIHByaW50aygiTWVtLWluZm86XG4iKTsKLSAgICAgICAgc2hvd19mcmVlX2FyZWFzKCk7Ci0gICAgICAgIHByaW50aygiRnJlZSBzd2FwOiAgICAgICAlNmxka0JcbiIsIG5yX3N3YXBfcGFnZXM8PChQQUdFX1NISUZULTEwKSk7Ci0gICAgICAgIHBmbiA9IG1heF9tYXBucjsKLSAgICAgICAgd2hpbGUocGZuLS0gPiAwKSB7CisJcHJpbnRrKCJNZW0taW5mbzpcbiIpOworCXNob3dfZnJlZV9hcmVhcygpOworCXByaW50aygiRnJlZSBzd2FwOiAgICAgICAlNmxka0JcbiIsIG5yX3N3YXBfcGFnZXM8PChQQUdFX1NISUZULTEwKSk7CisJcGZuID0gbWF4X21hcG5yOworCXdoaWxlKHBmbi0tID4gMCkgewogCQlwYWdlID0gcGZuX3RvX3BhZ2UocGZuKTsKLSAgICAgICAgICAgICAgICB0b3RhbCsrOwotICAgICAgICAgICAgICAgIGlmKFBhZ2VIaWdoTWVtKHBhZ2UpKQotICAgICAgICAgICAgICAgICAgICAgICAgaGlnaG1lbSsrOwotICAgICAgICAgICAgICAgIGlmKFBhZ2VSZXNlcnZlZChwYWdlKSkKLSAgICAgICAgICAgICAgICAgICAgICAgIHJlc2VydmVkKys7Ci0gICAgICAgICAgICAgICAgZWxzZSBpZihQYWdlU3dhcENhY2hlKHBhZ2UpKQotICAgICAgICAgICAgICAgICAgICAgICAgY2FjaGVkKys7Ci0gICAgICAgICAgICAgICAgZWxzZSBpZ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gMDsKKwlpZiAoYml0X21hc2sgJiBSVENfQUlFKQorCQlBSUVfb24gPSAwOworCisJcmV0dXJuIDE7Cit9CisKK2ludCBocGV0X3NldF9ydGNfaXJxX2JpdCh1bnNpZ25lZCBsb25nIGJpdF9tYXNrKQoreworCWludCB0aW1lcl9pbml0X3JlcWQgPSAwOworCisJaWYgKCFpc19ocGV0X2VuYWJsZWQoKSkKKwkJcmV0dXJuIDA7CisKKwlpZiAoIShQSUVfb24gfCBBSUVfb24gfCBVSUVfb24pKQorCQl0aW1lcl9pbml0X3JlcWQgPSAxOworCisJaWYgKGJpdF9tYXNrICYgUlRDX1VJRSkgeworCQlVSUVfb24gPSAxOworCX0KKwlpZiAoYml0X21hc2sgJiBSVENfUElFKSB7CisJCVBJRV9vbiA9IDE7CisJCVBJRV9jb3VudCA9IDA7CisJfQorCWlmIChiaXRfbWFzayAmIFJUQ19BSUUpIHsKKwkJQUlFX29uID0gMTsKKwl9CisKKwlpZiAodGltZXJfaW5pdF9yZXFkKQorCQlocGV0X3J0Y190aW1lcl9pbml0KCk7CisKKwlyZXR1cm4gMTsKK30KKworaW50IGhwZXRfc2V0X2FsYXJtX3RpbWUodW5zaWduZWQgY2hhciBocnMsIHVuc2lnbmVkIGNoYXIgbWluLCB1bnNpZ25lZCBjaGFyIHNlYykKK3sKKwlpZiAoIWlzX2hwZXRfZW5hYmxlZCgpKQorCQlyZXR1cm4gMDsKKworCWFsYXJtX3RpbWUudG1faG91ciA9IGhyczsKKwlhbGFybV90aW1lLnRtX21pbiA9IG1pbjsKKwlhbGFybV90aW1lLnRtX3NlYyA9IHNlYzsKKworCXJldHVybiAxOworfQorCitpbnQgaHBldF9zZXRfcGVyaW9kaWNfZnJlcSh1bnNpZ25lZCBsb25nIGZyZXEpCit7CisJaWYgKCFpc19ocGV0X2VuYWJsZWQoKSkKKwkJcmV0dXJuIDA7CisKKwlQSUVfZnJlcSA9IGZyZXE7CisJUElFX2NvdW50ID0gMDsKKworCXJldHVybiAxOwor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CS8qIGsxMyAqLworCVNVQkwoMTgpID0ga3JsbDsgU1VCUigxOCkgPSBrcmxyOworCS8qIGsxNCAqLworCVNVQkwoMTkpID0ga3JybDsgU1VCUigxOSkgPSBrcnJyOworCUNBTUVMTElBX1JPTERRbzMyKGtybGwsIGtybHIsIGtycmwsIGtycnIsIHcwLCB3MSwgMzQpOworCS8qIGsxOSAqLworCVNVQkwoMjYpID0ga3JsbDsgU1VCUigyNikgPSBrcmxyOworCS8qIGsyMCAqLworCVNVQkwoMjcpID0ga3JybDsgU1VCUigyNykgPSBrcnJyOworCUNBTUVMTElBX1JPTERRbzMyKGtybGwsIGtybHIsIGtycmwsIGtycnIsIHcwLCB3MSwgMzQpOworCisJLyogZ2VuZXJhdGUgS0EgKi8KKwlrbGwgPSBTVUJMKDApIF4ga3JsbDsga2xyID0gU1VCUigwKSBeIGtybHI7CisJa3JsID0gU1VCTCgxKSBeIGtycmw7IGtyciA9IFNVQlIoMSkgXiBrcnJyOworCUNBTUVMTElBX0Yoa2xsLCBrbHIsCisJCSAgIENBTUVMTElBX1NJR01BMUwsIENBTUVMTElBX1NJR01BMVIsCisJCSAgIHcwLCB3MSwgaWwsIGlyLCB0MCwgdDEpOworCWtybCBePSB3MDsga3JyIF49IHcxOworCUNBTUVMTElBX0Yoa3JsLCBrcnIsCisJCSAgIENBTUVMTElBX1NJR01BMkwsIENBTUVMTElBX1NJR01BMlIsCisJCSAgIGtsbCwga2xyLCBpbCwgaXIsIHQwLCB0MSk7CisJa2xsIF49IGtybGw7IGtsciBePSBrcmxyOworCUNBTUVMTElBX0Yoa2xsLCBrbHIsCisJCSAgIENBTUVMTElBX1NJR01BM0wsIENBTUVMTElBX1NJR01BM1IsCisJCSAgIGtybCwga3JyLCBpbCwgaXIsIHQwLCB0MSk7CisJa3JsIF49IHcwIF4ga3JybDsga3JyIF49IHcxIF4ga3JycjsKKwlDQU1FTExJQV9GKGtybCwga3JyLAorCQkgICBDQU1FTExJQV9TSUdNQTRMLCBDQU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aKDB4NjEpLCBaKDB4ZmYpLCBaKDB4NGEpLCBaKDB4NGEpLAorCVooMHgzNSksIFooMHhhYyksIFooMHhhYSksIFooMHg1ZiksIFooMHgyYiksIFooMHhiYiksIFooMHhiYyksIFooMHg1MyksCisJWigweDRlKSwgWigweDlkKSwgWigweDc4KSwgWigweGEzKSwgWigweGRjKSwgWigweDA5KSwgWigweDMyKSwgWigweDEwKSwKKwlaKDB4YzYpLCBaKDB4NmYpLCBaKDB4NjYpLCBaKDB4ZDYpLCBaKDB4YWIpLCBaKDB4YTkpLCBaKDB4YWYpLCBaKDB4ZmQpLAorCVooMHgzYiksIFooMHg5NSksIFooMHhlOCksIFooMHgzNCksIFooMHg5YSksIFooMHg4MSksIFooMHg3MiksIFooMHg4MCksCisJWigweDljKSwgWigweGYzKSwgWigweGVjKSwgWigweGRhKSwgWigweDlmKSwgWigweDI2KSwgWigweDc2KSwgWigweDE1KSwKKwlaKDB4M2UpLCBaKDB4NTUpLCBaKDB4NGQpLCBaKDB4ZGUpLCBaKDB4ODQpLCBaKDB4ZWUpLCBaKDB4YWQpLCBaKDB4YzcpLAorCVooMHhmMSksIFooMHg2YiksIFooMHgzZCksIFooMHhkMyksIFooMHgwNCksIFooMHg0OSksIFooMHhhYSksIFooMHgyNCksCisJWigweDBiKSwgWigweDhhKSwgWigweDgzKSwgWigweGJhKSwgWigweGZhKSwgWigweDg1KSwgWigweGEwKSwgWigweGE4KSwKKwlaKDB4YjEpLCBaKDB4ZDQpLCBaKDB4MDEpLCBaKDB4ZDgpLCBaKDB4NzApLCBaKDB4NjQpLCBaKDB4ZjApLCBaKDB4NTEpLAorCVooMHhkMiksIFooMHhjMyksIFooMHhhNyksIFooMHg3NSksIFooMHg4YyksIFooMHhhNSksIFooMHg2NCksIFooMHhlZiksCisJWigweDEwKSwgWigweDRlKSwgWigweGI3KSwgWigweGM2KSwgWigweDYxKSwgWigweDAzKSwgWigweGViKSwgWigweDQ0KSwKKwlaKDB4M2QpLCBaKDB4ZTUpLCBaKDB4YjMpLCBaKDB4NWIpLCBaKDB4YWUpLCBaKDB4ZDUpLCBaKDB4YWQpLCBaKDB4MWQpLAorCVooMHhmYSksIFooMHg1YSksIFooMHgxZSksIFooMHgzMyksIFooMHhhYiksIFooMHg5MyksIFooMHhhMiksIFooMHhiNyksCisJWigweGU3KSwgWigweGE4KSwgWigweDQ1KSwgWigweGE0KSwgWigweGNkKSwgWigweDI5KSwgWigweDYzKSwgWigweDQ0KSwKKwlaKDB4YjYpLCBaKDB4NjkpLCBaKDB4N2UpLCBaKDB4MmUpLCBaKDB4NjIpLCBaKDB4MDMpLCBaKDB4YzgpLCBaKDB4ZTApLAorCVooMHgxNyksIFooMHhiYiksIFooMHhjNyksIFooMHhmMyksIFooMHgzZiksIFooMHgzNiksIFooMHhiYSksIFooMHg3MSksCisJWigweDhlKSwgWigweDk3KSwgWigweDY1KSwgWigweDYwKSwgWigweDY5KSwgWigweGI2KSwgWigweGY2KSwgWigweGU2KSwKKwlaKDB4NmUpLCBaKDB4ZTApLCBaKDB4ODEpLCBaKDB4NTkpLCBaKDB4ZTgpLCBaKDB4YWYpLCBaKDB4ZGQpLCBaKDB4OTUpLAorCVooMHgyMiksIFooMHg5OSksIFooMHhmZCksIFooMHg2MyksIFooMHgxOSksIFooMHg3NCksIFooMHg2MSksIFooMHhiMSksCisJWigweGI2KSwgWigweDViKSwgWigweGFlKSwgWigweDU0KSwgWigweGIzKSwgWigweDcwKSwgWigweGZmKSwgWigweGM2KSwKKwlaKDB4M2IpLCBaKDB4M2UpLCBaKDB4YzEpLCBaKDB4ZDcpLCBaKDB4ZTEpLCBaKDB4MGUpLCBaKDB4NzYpLCBaKDB4ZTUpLAorCVooMHgzNiksIFooMHg0ZiksIFooMHg1OSksIFooMHhjNyksIFooMHgwOCksIFooMHg2ZSksIFooMHg4MiksIFooMHhhNiksCisJWigweDkzKSwgWigweGM0KSwgWigweGFhKSwgWigweDI2KSwgWigweDQ5KSwgWigweGUwKSwgWigweDIxKSwgWigweDY0KSwKKwlaKDB4MDcpLCBaKDB4OWYpLCBaKDB4NjQpLCBaKDB4ODEpLCBaKDB4OWMpLCBaKDB4YmYpLCBaKDB4ZjkpLCBaKDB4ZDEpLAorCVooMHg0MyksIFooMHhmOCksIFooMHhiNiksIFooMHhiOSksIFooMHhmMSksIFooMHgyNCksIFooMHg3NSksIFooMHgwMyksCisJWigweGU0KSwgWigweGIwKSwgWigweDk5KSwgWigweDQ2KSwgWigweDNkKSwgWigweGY1KSwgWigweGQxKSwgWigweDM5KSwKKwlaKDB4NzIpLCBaKDB4MTIpLCBaKDB4ZjYpLCBaKDB4YmEpLCBaKDB4MGMpLCBaKDB4MGQpLCBaKDB4NDIpLCBaKDB4MmUpCit9OworCisjdW5kZWYgWgorI2RlZmluZSBaKHgpIF9fY29uc3RhbnRfYmUzMl90b19jcHUoKHggPDwgMjcpIHwgKHggPj4gNSkpCitzdGF0aWMgY29uc3QgdTMyIHNib3gxWzI1Nl0gPSB7CisJWigweDc3KSwgWigweDE0KSwgWigweGE2KSwgWigweGZlKSwgWigweGIyKSwgWigweDVlKSwgWigweDhjKSwgWigweDNlKSwKKwlaKDB4NjcpLCBaKDB4NmMpLCBaKDB4YTEpLCBaKDB4MGQpLCBaKDB4YzIpLCBaKDB4YTIpLCBaKDB4YzEpLCBaKDB4ODUpLAorCVooMHg2YyksIFooMHg3YiksIFooMHg2NyksIFooMHhjNiksIFooMHgyMyksIFooMHhlMyksIFooMHhmMiksIFooMHg4OSksCisJWigweDUwKSwgWigweDljKSwgWigweDAzKSwgWigweGI3KSwgWigweDczKSwgWigweGU2KSwgWigweGUxKSwgWigweDM5KSwKKwlaKDB4MzEpLCBaKDB4MmMpLCBaKDB4MjcpLCBaKDB4OWYpLCBaKDB4YTUpLCBaKDB4NjkpLCBaKDB4NDQpLCBaKDB4ZDYpLAorCVooMHgyMyksIFooMHg4MyksIFooMHg5OCksIFooMHg3ZCksIFooMHgzYyksIFooMHhiNCksIFooMHgyZCksIFooMHg5OSksCisJWigweDFjKSwgWigweDFmKSwgWigweDhjKSwgWigweDIwKSwgWigweDAzKSwgWigweDdjKSwgWigweDVmKSwgWigweGFkKSwKKwlaKDB4ZjQpLCBaKDB4ZmEpLCBaKDB4OTUpLCBaKDB4Y2EpLCBaKDB4NzYpLCBaKDB4NDQpLCBaKDB4Y2QpLCBaKDB4YjYpLAorCVooMHhiOCksIFooMHhhMSksIFooMHhhMSksIFooMHhiZSksIFooMHg5ZSksIFooMHg1NCksIFooMHg4ZiksIFooMHgwYiksCisJWigweDE2KSwgWigweDc0KSwgWigweDMxKSwgWigweDhhKSwgWigweDIzKSwgWigweDE3KSwgWigweDA0KSwgWigweGZhKSwKKwlaKDB4NzkpLCBaKDB4ODQpLCBaKDB4YjEpLCBaKDB4ZjUpLCBaKDB4MTMpLCBaKDB4YWIpLCBaKDB4YjUpLCBaKDB4MmUpLAorCVooMHhhYSksIFooMHgwYyksIFooMHg2MCksIFooMHg2YiksIFooMHg1YiksIFooMHhjNCksIFooMHg0YiksIFooMHhiYyksCisJWigweGUyKSwgWigweGFmKSwgWigweDQ1KSwgWigweDczKSwgWigweGZhKSwgWigweGM5KSwgWigweDQ5KSwgWigweGNkKSwKKwlaKDB4MDApLCBaKDB4OTIpLCBaKDB4N2QpLCBaKDB4OTcpLCBaKDB4N2EpLCBaKDB4MTgpLCBaKDB4NjApLCBaKDB4M2QpLAorCVooMHhjZiksIFooMHg1YiksIFooMHhkZSksIFooMHhjNiksIFooMHhlMiksIFooMHhlNiksIFooMHhiYiksIFooMHg4YiksCisJWigweDA2KSwgWigweGRhKSwgWigweDA4KSwgWigweDE1KSwgWigweDFiKSwgWigweDg4KSwgWigweDZhKSwgWigweDE3KSwKKwlaKDB4ODkpLCBaKDB4ZDApLCBaKDB4YTkpLCBaKDB4YzEpLCBaKDB4YzkpLCBaKDB4NzApLCBaKDB4NmIpLCBaKDB4ZTUpLAorCVooMHg0MyksIFooMHhmNCksIFooMHg2OCksIFooMHhjOCksIFooMHhkMyksIFooMHg4NCksIFooMHgyOCksIFooMHgwYSksCisJWigweDUyKSwgWigweDY2KSwgWigweGEzKSwgWigweGNhKSwgWigweGYyKSwgWigweGUzKSwgWigweDdmKSwgWigweDdhKSwKKwlaKDB4MzEpLCBaKDB4ZjcpLCBaKDB4ODgpLCBaKDB4OTQpLCBaKDB4NWUpLCBaKDB4OWMpLCBaKDB4NjMpLCBaKDB4ZDUpLAorCVooMHgyNCksIFooMHg2NiksIFooMHhmYyksIFooMHhiMyksIFooMHg1NyksIFooMHgyNSksIFooMHhiZSksIFooMHg4OSksCisJWigweDQ0KSwgWigweGM0KSwgWigweGUwKSwgWigweDhmKSwgWigweDIzKSwgWigweDNjKSwgWigweDEyKSwgWigweDUyKSwKKwlaKDB4ZjUpLCBaKDB4MWUpLCBaKDB4ZjQpLCBaKDB4Y2IpLCBaKDB4MTgpLCBaKDB4MzMpLCBaKDB4MWYpLCBaKDB4ZjgpLAorCVooMHg2OSksIFooMHgxMCksIFooMHg5ZCksIFooMHhkMyksIFooMHhmNyksIFooMHgyOCksIFooMHhmOCksIFooMHgzMCksCisJWigweDA1KSwgWigweDVlKSwgWigweDMyKSwgWigweGMwKSwgWigweGQ1KSwgWigweDE5KSwgWigweGJkKSwgWigweDQ1KSwKKwlaKDB4OGIpLCBaKDB4NWIpLCBaKDB4ZmQpLCBaKDB4YmMpLCBaKDB4ZTIpLCBaKDB4NWMpLCBaKDB4YTkpLCBaKDB4OTYpLAorCVooMHhlZiksIFooMHg3MCksIFooMHhjZiksIFooMHhjMiksIFooMHgyYSksIFooMHhiMyksIFooMHg2MSksIFooMHhhZCksCisJWigweDgwKSwgWigweDQ4KSwgWigweDgxKSwgWigweGI3KSwgWigweDFkKSwgWigweDQzKSwgWigweGQ5KSwgWigweGQ3KSwKKwlaKDB4NDUpLCBaKDB4ZjApLCBaKDB4ZDgpLCBaKDB4OGEpLCBaKDB4NTkpLCBaKDB4N2MpLCBaKDB4NTcpLCBaKDB4YzEpLAorCVooMHg3OSksIFooMHhjNyksIFooMHgzNCksIFooMHhkNiksIFooMHg0MyksIFooMHhkZiksIFooMHhlNCksIFooMHg3OCksCisJWigweDE2KSwgWigweDA2KSwgWigweGRhKSwgWigweDkyKSwgWigweDc2KSwgWigweDUxKSwgWigweGUxKSwgWigweGQ0KSwKKwlaKDB4NzApLCBaKDB4MDMpLCBaKDB4ZTApLCBaKDB4MmYpLCBaKDB4OTYpLCBaKDB4OTEpLCBaKDB4ODIpLCBaKDB4ODApCit9OworCisjdW5kZWYgWgorI2RlZmluZSBaKHgpIF9fY29uc3RhbnRfYmUzMl90b19jcHUoeCA8PCAxMSkKK3N0YXRpYyBjb25zdCB1MzIgc2JveDJbMjU2XSA9IHsKKwlaKDB4ZjApLCBaKDB4MzcpLCBaKDB4MjQpLCBaKDB4NTMpLCBaKDB4MmEpLCBaKDB4MDMpLCBaKDB4ODMpLCBaKDB4ODYpLAorCVooMHhkMSksIFooMHhlYyksIFooMHg1MCksIFooMHhmMCksIFooMHg0MiksIFooMHg3OCksIFooMHgyZiksIFooMHg2ZCksCisJWigweGJmKSwgWigweDgwKSwgWigweDg3KSwgWigweDI3KSwgWigweDk1KSwgWigweGUyKSwgWigweGM1KSwgWigweDVkKSwKKwlaKDB4ZjkpLCBaKDB4NmYpLCBaKDB4ZGIpLCBaKDB4YjQpLCBaKDB4NjUpLCBaKDB4NmUpLCBaKDB4ZTcpLCBaKDB4MjQpLAorCVooMHhjOCksIFooMHgxYSksIFooMHhiYiksIFooMHg0OSksIFooMHhiNSksIFooMHgwYSksIFooMHg3ZCksIFooMHhiOSksCisJWigweGU4KSwgWigweGRjKSwgWigweGI3KSwgWigweGQ5KSwgWigweDQ1KSwgWigweDIwKSwgWigweDFiKSwgWigweGNlKSwKKwlaKDB4NTkpLCBaKDB4OWQpLCBaKDB4NmIpLCBaKDB4YmQpLCBaKDB4MGUpLCBaKDB4OGYpLCBaKDB4YTMpLCBaKDB4YTkpLAorCVooMHhiYyksIFooMHg3NCksIFooMHhhNiksIFooMHhmNiksIFooMHg3ZiksIFooMHg1ZiksIFooMHhiMSksIFooMHg2OCksCisJWigweDg0KSwgWigweGJjKSwgWigweGE5KSwgWigweGZkKSwgWigweDU1KSwgWigweDUwKSwgWigweGU5KSwgWigweGI2KSwKKwlaKDB4MTMpLCBaKDB4NWUpLCBaKDB4MDcpLCBaKDB4YjgpLCBaKDB4OTUpLCBaKDB4MDIpLCBaKDB4YzApLCBaKDB4ZDApLAorCVooMHg2YSksIFooMHgxYSksIFooMHg4NSksIFooMHhiZCksIFooMHhiNiksIFooMHhmZCksIFooMHhmZSksIFooMHgxNyksCisJWigweDNmKSwgWigweDA5KSwgWigweGEzKSwgWigweDhkKSwgWigweGZiKSwgWigweGVkKSwgWigweGRhKSwgWigweDFkKSwKKwlaKDB4NmQpLCBaKDB4MWMpLCBaKDB4NmMpLCBaKDB4MDEpLCBaKDB4NWEpLCBaKDB4ZTUpLCBaKDB4NzEpLCBaKDB4M2UpLAorCVooMHg4YiksIFooMHg2YiksIFooMHhiZSksIFooMHgyOSksIFooMHhlYiksIFooMHgxMiksIFooMHgxOSksIFooMHgzNCksCisJWigweGNkKSwgWigweGIzKSwgWigweGJkKSwgWigweDM1KSwgWigweGVhKSwgWigweDRiKSwgWigweGQ1KSwgWigweGFlKSwKKwlaKDB4MmEpLCBaKDB4NzkpLCBaKDB4NWEpLCBaKDB4YTUpLCBaKDB4MzIpLCBaKDB4MTIpLCBaKDB4N2IpLCBaKDB4ZGMpLAorCVooMHgyYyksIFooMHhkMCksIFooMHgyMiksIFooMHg0YiksIFooMHhiMSksIFooMHg4NSksIFooMHg1OSksIFooMHg4MCksCisJWigweGMwKSwgWigweDMwKSwgWigweDlmKSwgWigweDczKSwgWigweGQzKSwgWigweDE0KSwgWigweDQ4KSwgWigweDQwKSwKKwlaKDB4MDcpLCBaKDB4MmQpLCBaKDB4OGYpLCBaKDB4ODApLCBaKDB4MGYpLCBaKDB4Y2UpLCBaKDB4MGIpLCBaKDB4NWUpLAorCVooMHhiNyksIFooMHg1ZSksIFooMHhhYyksIFooMHgyNCksIFooMHg5NCksIFooMHg0YSksIFooMHgxOCksIFooMHgxNSksCisJWigweDA1KSwgWigweGU4KSwgWigweDAyKSwgWigweDc3KSwgWigweGE5KSwgWigweGM3KSwgWigweDQwKSwgWigweDQ1KSwKKwlaKDB4ODkpLCBaKDB4ZDEpLCBaKDB4ZWEpLCBaKDB4ZGUpLCBaKDB4MGMpLCBaKDB4NzkpLCBaKDB4MmEpLCBaKDB4OTkpLAorCVooMHg2YyksIFooMHgzZSksIFooMHg5NSksIFooMHhkZCksIFooMHg4YyksIFooMHg3ZCksIFooMHhhZCksIFooMHg2ZiksCisJWigweGRjKSwgWigweGZmKSwgWigweGZkKSwgWigweDYyKSwgWigweDQ3KSwgWigweGIzKSwgWigweDIxKSwgWigweDhhKSwKKwlaKDB4ZWMpLCBaKDB4OGUpLCBaKDB4MTkpLCBaKDB4MTgpLCBaKDB4YjQpLCBaKDB4NmUpLCBaKDB4M2QpLCBaKDB4ZmQpLAorCVooMHg3NCksIFooMHg1NCksIFooMHgxZSksIFooMHgwNCksIFooMHg4NSksIFooMHhkOCksIFooMHhiYyksIFooMHgxZiksCisJWigweDU2KSwgWigweGU3KSwgWigweDNhKSwgWigweDU2KSwgWigweDY3KSwgWigweGQ2KSwgWigweGM4KSwgWigweGE1KSwKKwlaKDB4ZjMpLCBaKDB4OGUpLCBaKDB4ZGUpLCBaKDB4YWUpLCBaKDB4MzcpLCBaKDB4NDkpLCBaKDB4YjcpLCBaKDB4ZmEpLAorCVooMHhjOCksIFooMHhmNCksIFooMHgxZiksIFooMHhlMCksIFooMHgyYSksIFooMHg5YiksIFooMHgxNSksIFooMHhkMSksCisJWigweDM0KSwgWigweDBlKSwgWigweGI1KSwgWigweGUwKSwgWigweDQ0KSwgWigweDc4KSwgWigweDg0KSwgWigweDU5KSwKKwlaKDB4NTYpLCBaKDB4NjgpLCBaKDB4NzcpLCBaKDB4YTUpLCBaKDB4MTQpLCBaKDB4MDYpLCBaKDB4ZjUpLCBaKDB4MmYpLAorCVooMHg4YyksIFooMHg4YSksIFooMHg3MyksIFooMHg4MCksIFooMHg3NiksIFooMHhiNCksIFooMHgxMCksIFooMHg4NikKK307CisKKyN1bmRlZiBaCisjZGVmaW5lIFooeCkgX19jb25zdGFudF9iZTMyX3RvX2NwdSh4IDw8IDE5KQorc3RhdGljIGNvbnN0IHUzMiBzYm94M1syNTZdID0geworCVooMHhhOSksIFooMHgyYSksIFooMHg0OCksIFooMHg1MSksIFooMHg4NCksIFooMHg3ZSksIFooMHg0OSksIFooMHhlMiksCisJWigweGI1KSwgWigweGI3KSwgWigweDQyKSwgWigweDMzKSwgWigweDdkKSwgWigweDVkKSwgWigweGE2KSwgWigweDEyKSwKKwlaKDB4NDQpLCBaKDB4NDgpLCBaKDB4NmQpLCBaKDB4MjgpLCBaKDB4YWEpLCBaKDB4MjApLCBaKDB4NmQpLCBaKDB4NTcpLAorCVooMHhkNiksIFooMHg2YiksIFooMHg1ZCksIFooMHg3MiksIFooMHhmMCksIFooMHg5MiksIFooMHg1YSksIFooMHgxYiksCisJWigweDUzKSwgWigweDgwKSwgWigweDI0KSwgWigweDcwKSwgWigweDlhKSwgWigweGNjKSwgWigweGE3KSwgWigweDY2KSwKKwlaKDB4YTEpLCBaKDB4MDEpLCBaKDB4YTUpLCBaKDB4NDEpLCBaKDB4OTcpLCBaKDB4NDEpLCBaKDB4MzEpLCBaKDB4ODIpLAorCVooMHhmMSksIFooMHgxNCksIFooMHhjZiksIFooMHg1MyksIFooMHgwZCksIFooMHhhMCksIFooMHgxMCksIFooMHhjYyksCisJWigweDJhKSwgWigweDdkKSwgWigweGQyKSwgWigweGJmKSwgWigweDRiKSwgWigweDFhKSwgWigweGRiKSwgWigweDE2KSwKKwlaKDB4NDcpLCBaKDB4ZjYpLCBaKDB4NTEpLCBaKDB4MzYpLCBaKDB4ZWQpLCBaKDB4ZjMpLCBaKDB4YjkpLCBaKDB4MWEpLAorCVooMHhhNyksIFooMHhkZiksIFooMHgyOSksIFooMHg0MyksIFooMHgwMSksIFooMHg1NCksIFooMHg3MCksIFooMHhhNCksCisJWigweGJmKSwgWigweGQ0KSwgWigweDBiKSwgWigweDUzKSwgWigweDQ0KSwgWigweDYwKSwgWigweDllKSwgWigweDIzKSwKKwlaKDB4YTEpLCBaKDB4MTgpLCBaKDB4NjgpLCBaKDB4NGYpLCBaKDB4ZjApLCBaKDB4MmYpLCBaKDB4ODIpLCBaKDB4YzIpLAorCVooMHgyYSksIFooMHg0MSksIFooMHhiMiksIFooMHg0MiksIFooMHgwYyksIFooMHhlZCksIFooMHgwYyksIFooMHgxZCksCisJWigweDEzKSwgWigweDNhKSwgWigweDNjKSwgWigweDZlKSwgWigweDM1KSwgWigweGRjKSwgWigweDYwKSwgWigweDY1KSwKKwlaKDB4ODUpLCBaKDB4ZTkpLCBaKDB4NjQpLCBaKDB4MDIpLCBaKDB4OWEpLCBaKDB4M2YpLCBaKDB4OWYpLCBaKDB4ODcpLAorCVooMHg5NiksIFooMHhkZiksIFooMHhiZSksIFooMHhmMiksIFooMHhjYiksIFooMHhlNSksIFooMHg2YyksIFooMHhkNCksCisJWigweDVhKSwgWigweDgzKSwgWigweGJmKSwgWigweDkyKSwgWigweDFiKSwgWigweDk0KSwgWigweDAwKSwgWigweDQyKSwKKwlaKDB4Y2YpLCBaKDB4NGIpLCBaKDB4MDApLCBaKDB4NzUpLCBaKDB4YmEpLCBaKDB4OGYpLCBaKDB4NzYpLCBaKDB4NWYpLAorCVooMHg1ZCksIFooMHgzYSksIFooMHg0ZCksIFooMHgwOSksIFooMHgxMiksIFooMHgwOCksIFooMHgzOCksIFooMHg5NSksCisJWigweDE3KSwgWigweGU0KSwgWigweDAxKSwgWigweDFkKSwgWigweDRjKSwgWigweGE5KSwgWigweGNjKSwgWigweDg1KSwKKwlaKDB4ODIpLCBaKDB4NGMpLCBaKDB4OWQpLCBaKDB4MmYpLCBaKDB4M2IpLCBaKDB4NjYpLCBaKDB4YTEpLCBaKDB4MzQpLAorCVooMHgxMCksIFooMHhjZCksIFooMHg1OSksIFooMHg4OSksIFooMHhhNSksIFooMHgzMSksIFooMHhjZiksIFooMHgwNSksCisJWigweGM4KSwgWigweDg0KSwgWigweGZhKSwgWigweGM3KSwgWigweGJhKSwgWigweDRlKSwgWigweDhiKSwgWigweDFhKSwKKwlaKDB4MTkpLCBaKDB4ZjEpLCBaKDB4YTEpLCBaKDB4M2IpLCBaKDB4MTgpLCBaKDB4MTIpLCBaKDB4MTcpLCBaKDB4YjApLAorCVooMHg5OCksIFooMHg4ZCksIFooMHgwYiksIFooMHgyMyksIFooMHhjMyksIFooMHgzYSksIFooMHgyZCksIFooMHgyMCksCisJWigweGRmKSwgWigweDEzKSwgWigweGEwKSwgWigweGE4KSwgWigweDRjKSwgWigweDBkKSwgWigweDZjKSwgWigweDJmKSwKKwlaKDB4NDcpLCBaKDB4MTMpLCBaKDB4MTMpLCBaKDB4NTIpLCBaKDB4MWYpLCBaKDB4MmQpLCBaKDB4ZjUpLCBaKDB4NzkpLAorCVooMHgzZCksIFooMHhhMiksIFooMHg1NCksIFooMHhiZCksIFooMHg2OSksIFooMHhjOCksIFooMHg2YiksIFooMHhmMyksCisJWigweDA1KSwgWigweDI4KSwgWigweGYxKSwgWigweDE2KSwgWigweDQ2KSwgWigweDQwKSwgWigweGIwKSwgWigweDExKSwKKwlaKDB4ZDMpLCBaKDB4YjcpLCBaKDB4OTUpLCBaKDB4NDkpLCBaKDB4Y2YpLCBaKDB4YzMpLCBaKDB4MWQpLCBaKDB4OGYpLAorCVooMHhkOCksIFooMHhlMSksIFooMHg3MyksIFooMHhkYiksIFooMHhhZCksIFooMHhjOCksIFooMHhjOSksIFooMHhhOSksCisJWigweGExKSwgWigweGMyKSwgWigweGM1KSwgWigweGUzKSwgWigweGJhKSwgWigweGZjKSwgWigweDBlKSwgWigweDI1KQorfTsKKworLyoKKyAqIFRoaXMgaXMgYSAxNiByb3VuZCBG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ZSBhZnRlciBJZGVudGlmeSAoUGFja2V0KSBEZXZpY2UgLS0gdXNlcyBpdHMgZGF0YQorICogQVRNIHRoaXMgZnVuY3Rpb24gbmV2ZXIgcmV0dXJucyBhIGZhaWx1cmUuICBJdCBpcyBhbiBvcHRpb25hbAorICogbWV0aG9kIGFuZCBpZiBpdCBmYWlscyBmb3Igd2hhdGV2ZXIgcmVhc29uLCB3ZSBzaG91bGQgc3RpbGwKKyAqIGp1c3Qga2VlcCBnb2luZy4KKyAqLworaW50IGF0YV9hY3BpX3B1c2hfaWQoc3RydWN0IGF0YV9wb3J0ICphcCwgdW5zaWduZWQgaW50IGl4KQoreworCWFjcGlfaGFuZGxlICAgICAgICAgICAgICAgICAgICAgaGFuZGxlOworCWFjcGlfaW50ZWdlciAgICAgICAgICAgICAgICAgICAgcGNpZGV2Zm47CisJaW50ICAgICAgICAgICAgICAgICAgICAgICAgICAgICBlcnI7CisJc3RydWN0IGRldmljZSAgICAgICAgICAgICAgICAgICAqZGV2ID0gYXAtPmhvc3QtPmRldjsKKwlzdHJ1Y3QgYXRhX2RldmljZSAgICAgICAgICAgICAgICphdGFkZXYgPSAmYXAtPmRldmljZVtpeF07CisJdTMyICAgICAgICAgICAgICAgICAgICAgICAgICAgICBkZXZfYWRyOworCWFjcGlfc3RhdHVzICAgICAgICAgICAgICAgICAgICAgc3RhdHVzOworCXN0cnVjdCBhY3BpX29iamVjdF9saXN0ICAgICAgICAgaW5wdXQ7CisJdW5pb24gYWNwaV9vYmplY3QgICAgICAgICAgICAgICBpbl9wYXJhbXNbMV07CisKKwlpZiAobm9hY3BpKQorCQlyZXR1cm4gMDsKKworCWlmIChhdGFfbXNnX3Byb2JlKGFwKSkKKwkJYXRhX2Rldl9wcmludGsoYXRhZGV2LCBLRVJOX0RFQlVHLAorCQkJIiVzOiBhcC0+aWQ6ICVkLCBpeCA9ICVkLCBwb3J0IzogJWRcbiIsCisJCQlfX0ZVTkNUSU9OX18sIGFwLT5pZCwgaXgsIGF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worCXU4ICByZXNlcnZlZDIwWzNdOworCXU4ICB0Zl9jb21tYW5kOwkJLyogQVRBICsgMHg3YyBUQVNLRklMRSBDb21tYW5kL1N0YXR1cyAqLworCXU4ICBkbWFfbW9kZTsJCS8qIEFUQSArIDB4N2QgQVRBIEhvc3QgRE1BIE1vZGUgY29uZmlndXJhdGlvbiAqLworCXU4ICByZXNlcnZlZDIxWzJdOworfTsKKworCisvKiA9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0gKi8KKy8qIEF1eCBmbnMgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqLworLyogPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09ICovCisKKworLyogTVBDNTJ4eCBsb3cgbGV2ZWwgaHcgY29udHJvbCAqLworCitzdGF0aWMgaW50CittcGM1Mnh4X2F0YV9jb21wdXRlX3Bpb190aW1pbmdzKHN0cnVjdCBtcGM1Mnh4X2F0YV9wcml2ICpwcml2LCBpbnQgZGV2LCBpbnQgcGlvKQoreworCXN0cnVjdCBtcGM1Mnh4X2F0YV90aW1pbmdzICp0aW1pbmcgPSAmcHJpdi0+dGltaW5nc1tkZXZdOworCXVuc2lnbmVkIGludCBpcGJfcGVyaW9kID0gcHJpdi0+aXBiX3BlcmlvZDsKKwl1bnNpZ25lZCBpbnQgdDAsIHQxLCB0Ml84LCB0Ml8xNiwgdDJpLCB0NCwgdGE7CisKKwlpZiAoKHBpbzwwKSB8fCAocGlvPjQpKQorCQlyZXR1cm4gLUVJTlZBTDsKKworCXQwCT0gQ0FMQ19DTEtDWUMoaXBiX3BlcmlvZCwgMTAwMCAqIGF0YXNwZWNfdDBbcGlvXSk7CisJdDEJPSBDQUxDX0NMS0NZQyhpcGJfcGVyaW9kLCAxMDAwICogYXRhc3Bl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KKwkvKiBJbml0IHRpbWluZ3MgdG8gUElPMCAqLworCW1lbXNldChwcml2LT50aW1pbmdzLCAweDAwLCAyKnNpemVvZihzdHJ1Y3QgbXBjNTJ4eF9hdGFfdGltaW5ncykpOworCisJbXBjNTJ4eF9hdGFfY29tcHV0ZV9waW9fdGltaW5ncyhwcml2LCAwLCAwKTsKKwltcGM1Mnh4X2F0YV9jb21wdXRlX3Bpb190aW1pbmdzKHByaXYsIDEsIDApOworCisJbXBjNTJ4eF9hdGFfYXBwbHlfdGltaW5ncyhwcml2LCAwKTsKKworCXJldHVybiAwOworfQorCisKKy8qID09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PSAqLworLyogbGliYXRhIGRyaXZlciAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICovCisvKiA9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0gKi8KKworc3RhdGljIHZvaWQKK21wYzUyeHhfYXRhX3NldF9waW9tb2RlKHN0cnVjdCBhdGFfcG9ydCAqYXAsIHN0cnVjdCBhdGFfZGV2aWNlICphZGV2KQoreworCXN0cnVjdCBtcGM1Mnh4X2F0YV9wcml2ICpwcml2ID0gYXAtPmhvc3QtPnByaXZhdGVfZGF0YTsKKwlpbnQgcGlvLCBydjsKKworCXBpbyA9IGFkZXYtPnBpb19tb2RlIC0gWEZFUl9QSU9fMDsKKworCXJ2ID0gbXBjNTJ4eF9hdGFfY29tcHV0ZV9waW9fdGltaW5ncyhwcml2LCBhZGV2LT5kZXZubywgcGlvKTsKKworCWlmIChydikgeworCQlwcmludGsoS0VSTl9FUlIgRFJWX05BTUUKKwkJCSI6IFRyeWluZyB0byBzZWxlY3QgaW52YWxpZCBQSU8gbW9kZSAlZFxuIiwgcGlvKTsKKwkJcmV0dXJuOworCX0KKwor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cml2ICpwcml2ID0gaG9zdC0+cHJpdmF0ZV9kYXRhOworCisJYXRhX2hvc3RfZGV0YWNoKGhvc3QpOworCisJcmV0dXJuIHByaXY7Cit9CisKKworLyogPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09ICovCisvKiBPRiBQbGF0Zm9ybSBkcml2ZXIgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKi8KKy8qID09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PSAqLworCitzdGF0aWMgaW50IF9fZGV2aW5pdAorbXBjNTJ4eF9hdGFfcHJvYmUoc3RydWN0IG9mX2RldmljZSAqb3AsIGNvbnN0IHN0cnVjdCBvZl9kZXZpY2VfaWQgKm1hdGNoKQoreworCXVuc2lnbmVkIGludCBpcGJfZnJlcTsKKwlzdHJ1Y3QgcmVzb3VyY2UgcmVzX21lbTsKKwlpbnQgYXRhX2lycSA9IE5PX0lSUTsKKwlzdHJ1Y3QgbXBjNTJ4eF9hdGEgX19pb21lbSAqYXRhX3JlZ3M7CisJc3RydWN0IG1wYzUyeHhfYXRhX3ByaXYgKnByaXY7CisJaW50IHJ2OworCisJLyogR2V0IGlwYiBmcmVxdWVuY3kgKi8KKwlpcGJfZnJlcSA9IG1wYzUyeHhfZmluZF9pcGJfZnJlcShvcC0+bm9kZSk7CisJaWYgKCFpcGJfZnJlcSkgeworCQlwcmludGsoS0VSTl9FUlIgRFJWX05BTUUgIjogIgorCQkJIlVuYWJsZSB0byBmaW5kIElQQiBCdXMgZnJlcXVlbmN5XG4iICk7CisJCXJldHVybiAtRU5PREVWOworCX0KKworCS8qIEdldCBJUlEgYW5kIHJlZ2lzdGVyICovCisJcnYgPSBvZl9hZGRyZXNzX3RvX3Jlc291cmNlKG9wLT5ub2RlLCAwLCAmcmVzX21lbSk7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kLAorCS5yZXN1bWUJCT0gbXBjNTJ4eF9hdGFfcmVzdW1lLAorI2VuZGlmCisJLmRyaXZlcgkJPSB7CisJCS5uYW1lCT0gRFJWX05BTUUsCisJCS5vd25lcgk9IFRISVNfTU9EVUxFLAorCX0sCit9OworCisKKy8qID09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PSAqLworLyogTW9kdWxlICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICovCisvKiA9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0gKi8KKworc3RhdGljIGludCBfX2luaXQKK21wYzUyeHhfYXRhX2luaXQodm9pZCkKK3sKKwlwcmludGsoS0VSTl9JTkZPICJhdGE6IE1QQzUyeHggSURFL0FUQSBsaWJhdGEgZHJpdmVyXG4iKTsKKwlyZXR1cm4gb2ZfcmVnaXN0ZXJfcGxhdGZvcm1fZHJpdmVyKCZtcGM1Mnh4X2F0YV9vZl9wbGF0Zm9ybV9kcml2ZXIpOworfQorCitzdGF0aWMgdm9pZCBfX2V4aXQKK21wYzUyeHhfYXRhX2V4aXQodm9pZCkKK3sKKwlvZl91bnJlZ2lzdGVyX3BsYXRmb3JtX2RyaXZlcigmbXBjNTJ4eF9hdGFfb2ZfcGxhdGZvcm1fZHJpdmVyKTsKK30KKworbW9kdWxlX2luaXQobXBjNTJ4eF9hdGFfaW5pdCk7Cittb2R1bGVfZXhpdChtcGM1Mnh4X2F0YV9leGl0KTsKKworTU9EVUxFX0FVVEhPUigiU3lsdmFpbiBNdW5hdXQgPHRudEAyNDZ0TnQuY29tPiIpOworTU9EVUxFX0RFU0NSSVBUSU9OKCJGcmVlc2NhbGUgTVBDNTJ4eCBJREUvQVRBIGxpYmF0YSBkcml2ZXIiKTsKK01PRFVMRV9MSUNFTlN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0ZVNjYW47CisgICAgICBib29sIFJlYnVpbGRQcm9ncmVzc0ZpcnN0OworICAgICAgYm9vbCBSZWJ1aWxkRmxhZ1BlbmRpbmc7CisgICAgICBib29sIFJlYnVpbGRTdGF0dXNQZW5kaW5nOwogCiAgICAgICBkbWFfYWRkcl90CUZpcnN0Q29tbWFuZE1haWxib3hETUE7CiAgICAgICBEQUM5NjBfVjFfQ29tbWFuZE1haWxib3hfVCAqRmlyc3RDb21tYW5kTWFpbGJveDsKQEAgLTI0MzIsMTcgKzI0MjUsMTcgQEAKICAgICAgIGRtYV9hZGRyX3QgTmV3SW5xdWlyeVVuaXRTZXJpYWxOdW1iZXJETUE7CiAKICAgICAgIGludCBEZXZpY2VSZXNldENvdW50W0RBQzk2MF9WMV9NYXhDaGFubmVsc11bREFDOTYwX1YxX01heFRhcmdldHNdOwotICAgICAgYm9vbGVhbiBEaXJlY3RDb21tYW5kQWN0aXZlW0RBQzk2MF9WMV9NYXhDaGFubmVsc11bREFDOTYwX1YxX01heFRhcmdldHNdOworICAgICAgYm9vbCBEaXJlY3RDb21tYW5kQWN0aXZlW0RBQzk2MF9WMV9NYXhDaGFubmVsc11bREFDOTYwX1YxX01heFRhcmdldHNdOwogICAgIH0gVjE7CiAgICAgc3RydWN0IHsKICAgICAgIHVuc2lnbmVkIGludCBTdGF0dXNDaGFuZ2VDb3VudGVyOwogICAgICAgdW5zaWduZWQgaW50IE5leHRFdmVudFNlcXVlbmNlTnVtYmVyOwogICAgICAgdW5zaWduZWQgaW50IFBoeXNpY2FsRGV2aWNlSW5kZXg7Ci0gICAgICBib29sZWFuIE5lZWRMb2dpY2FsRGV2aWNlSW5mb3JtYXRpb247Ci0gICAgICBib29sZWFuIE5lZWRQaHlzaWNhbERldmljZUluZm9ybWF0aW9uOwotICAgICAgYm9vbGVhbiBOZWVkRGV2aWNlU2VyaWFsTnVtYmVySW5mb3JtYXRpb247Ci0gICAgICBib29sZWFuIFN0YXJ0TG9naWNhbERldmljZUluZm9yb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AqCTI1LiBNb3hhUG9ydFR4RW5hYmxlKGludCBwb3J0KTsgCQkJCSAgICAgKgotICoJMjYuIE1veGFQb3J0R2V0QnJrQ250KGludCBwb3J0KTsJCQkJICAgICAqCiAgKgkyNy4gTW94YVBvcnRSZXNldEJya0NudChpbnQgcG9ydCk7CQkJCSAgICAgKgotICoJMjguIE1veGFQb3J0U2V0WG9uWG9mZihpbnQgcG9ydCwgaW50IHhvblZhbHVlLCBpbnQgeG9mZlZhbHVlKTsJICAgICAqCi0gKgkyOS4gTW94YVBvcnRJc1R4SG9sZChpbnQgcG9ydCk7IAkJCQkgICAgICoKICAqCTMwLiBNb3hhUG9ydFNlbmRCcmVhayhpbnQgcG9ydCwgaW50IHRpY2tzKTsJCQkgICAgICoKICAqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKi8KIC8qCkBAIC0xODc4LDE1ICsxNzg1LDYgQEAKICAqICAgICAgICAgICAgICAgICAgICAgIDM4NDAwLzU3NjAwLzExNTIwMCBicHMKICAqCiAgKgotICogICAgICBGdW5jdGlvbiA5OiAgICAgR2V0IHRoZSBjdXJyZW50IGJhdWQgcmF0ZSBvZiB0aGlzIHBvcnQuCi0gKiAgICAgIFN5bnRheDoKLSAqICAgICAgbG9uZyBNb3hhUG9ydEdldEN1ckJhdWQoaW50IHBvcnQpOwotICogICAgICAgICAgIGludCBwb3J0ICAgICAgICAgICA6IHBvcnQgbnVtYmVyICgwIC0gMTI3KQotICoKLSAqICAgICAgICAgICByZXR1cm46ICAgIDAgICAgICAgOiB0aGlzIHBvcnQgaXMgaW52YWxpZAotICogICAgICAgICAgICAgICAgICAgICAgNTAgLSAxMTUyMDAgYnBzCi0gKgotICoKICAqICAgICAgRnVuY3Rpb24gMTA6ICAgIFNldHRpbmcgYmF1ZCByYXRlIG9mIHRoaXMgcG9ydC4KICAqICAgICAgU3ludGF4OgogICogICAgICBsb25nIE1veGFQb3J0U2V0QmF1ZChpbnQgcG9ydCwgbG9uZyBiYXVkKTsKQEAgLTE5MDAsMTggKzE3OTgsNiBAQAogICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBiYXVkIHJhdGUgd2lsbCBiZSB0aGUgbWF4aW11biBiYXVkIHJhdGUuCiAgKgogICoKLSAqICAgICAgRnVuY3Rpb24gMTE6ICAgIFNldHRpbmcgdGhlIGRhdGEtYml0cy9zdG9wLWJpdHMvcGFyaXR5IG9mIHRoaXMgcG9ydAotICogICAgICBTeW50YXg6Ci0gKiAgICAgIGludCAgTW94YVBvcnRTZXRNb2RlKGludCBwb3J0LCBpbnQgZGF0YWJpdHMsIGludCBzdG9wYml0cywgaW50IHBhcml0eSk7Ci0gKiAgICAgICAgICAgaW50IHBvcnQgICAgICAgICAgIDogcG9ydCBudW1iZXIgKDAgLSAxMjcpCi0gKiAgICAgICAgICAgaW50IGRhdGFiaXRzICAgICAgIDogZGF0YSBiaXRzICg4LzcvNi81KQotICogICAgICAgICAgIGludCBzdG9wYml0cyAgICAgICA6IHN0b3AgYml0cyAoMi8xLzAsIDAgc2hvdyAxLjUgc3RvcCBiaXRzKQotIGludCBwYXJpdHkgICAgIDogcGFyaXR5ICgwOk5vbmUsMTpPZGQsMjpFdmVuLDM6TWFyayw0OlNwYWNlKQotICoKLSAqICAgICAgICAgICByZXR1cm46ICAgIC0xICAgICAgOiBpbnZhbGlkIHBhcmFtZXRlcgotICogICAgICAgICAgICAgICAgICAgICAgMCAgICAgICA6IHNldHRpbmcgTy5LLgotICoKLSAqCiAgKiAgICAgIEZ1bmN0aW9uIDEyOiAgICBDb25maWd1cmUgdGhlIHBvcnQuCiAgKiAgICAgIFN5bnRheDoKICAqICAgICAgaW50ICBNb3hhUG9ydFNldFRlcm1pbyhpbnQgcG9ydCwgc3RydWN0IGt0ZXJtaW9zICp0ZXJtaW8sIHNwZWVkX3QgYmF1ZCk7CkBAIC0yMDE2LDIyICsxOTAyLDYgQEAKICAqICAgICAgICAgICByZXR1cm46ICAgIDAgLSBsZW5ndGggICAgICA6IHJlYWwgcmVhZCBkYXRhIGxlbmd0aAogICoKICAqCi0gKiAgICAgIEZ1bmN0aW9uIDIyOiAgICBHZXQgdGhlIFR4IGJ1ZmZlciBzaXplIG9mIHRoaXMgcG9ydAotICogICAgICBTeW50YXg6Ci0gKiAgICAgIGludCAgTW94YVBvcnRUeEJ1ZlNpemUoaW50IHBvcnQpOwotICogICAgICAgICAgIGludCBwb3J0ICAgICAgICAgICA6IHBvcnQgbnVtYmVyICgwIC0gMTI3KQotICoKLSAqICAgICAgICAgICByZXR1cm46ICAgIC4uICAgICAgOiBUeCBidWZmZXIgc2l6ZQotICoKLSAqCi0gKiAgICAgIEZ1bmN0aW9uIDIzOiAgICBHZXQgdGhlIFJ4IGJ1ZmZlciBzaXplIG9mIHRoaXMgcG9ydAotICogICAgICBTeW50YXg6Ci0gKiAgICAgIGludCAgTW94YVBvcnRSeEJ1ZlNpemUoaW50IHBvcnQpOwotICogICAgICAgICAgIGludCBwb3J0ICAgICAgICAgICA6IHBvcnQgbnVtYmVyICgwIC0gMTI3KQotICoKLSAqICAgICAgICAgICByZXR1cm46ICAgIC4uICAgICAgOiBSeCBidWZmZXIgc2l6ZQotICoKLSAqCiAgKiAgICAgIEZ1bmN0aW9uIDI0OiAgICBHZXQgdGhlIFR4IGJ1ZmZlciBjdXJyZW50IHF1ZXVlZCBkYXRhIGJ5dGVzCiAgKiAgICAgIFN5bnRheDoKICAqICAgICAgaW50ICBNb3hhUG9ydFR4UXVldWUoaW50IHBvcnQpOwpAQCAtMjA1NiwxNCArMTkyNiw2IEBACiAgKiAgICAgICAgICAgcmV0dXJuOiAgICAuLiAgICAgIDogUnggYnVmZmVyIGN1cnJlbnQgcXVldWVkIGRhdGEgYnl0ZXMKICAqCiAgKgotICogICAgICBGdW5jdGlvbiAyNzogICAgR2V0IHRoZSBSeCBidWZmZXIgY3VycmVudCBmcmVlIHNwYWNlCi0gKiAgICAgIFN5bnRheDoKLSAqICAgICAgaW50ICBNb3hhUG9ydFJ4RnJlZShpbnQgcG9ydCk7Ci0gKiAgICAgICAgICAgaW50IHBvcnQgICAgICAgICAgIDogcG9ydCBudW1iZXIgKDAgLSAxMjcpCi0gKgotICogICAgICAgICAgIHJldHVybjogICAgLi4gICAgICA6IFJ4IGJ1ZmZlciBjdXJyZW50IGZyZWUgc3BhY2UKLSAqCi0gKgogICogICAgICBGdW5jdGlvbiAyODogICAgRGlzYWJsZSBwb3J0IGRhdGEgdHJhbnNtaXNzaW9uLgogICogICAgICBTeW50YXg6CiAgKiAgICAgIHZvaWQgTW94YVBvcnRUeERpc2FibGUoaW50IHBvcnQpOwpAQCAtMjA3NiwxNCArMTkzOCw2IEBACiAgKiAgICAgICAgICAgaW50IHBvcnQgICAgICAgICAgIDogcG9ydCBudW1iZXIgKDAgLSAxMjcpCiAgKgogICoKLSAqICAgICAgRnVuY3Rpb24gMzA6ICAgIEdldCB0aGUgcmVjZWl2ZWQgQlJFQUsgc2lnbmFsIGNvdW50LgotICogICAgICBTeW50YXg6Ci0gKiAgICAgIGludCAgTW94YVBvcnRHZXRCcmtDbnQoaW50IHBvcnQpOwotICogICAgICAgICAgIGludCBwb3J0ICAgICAgICAgICA6IHBvcnQgbnVtYmVyICgwIC0gMTI3KQotICoKLSAqICAgICAgICAgICByZXR1cm46ICAgIDAgLSAuLiAgOiBCUkVBSyBzaWduYWwgY291bnQKLSAqCi0gKgogICogICAgICBGdW5jdGlvbiAzMTogICAgR2V0IHRoZSByZWNlaXZlZCBCUkVBSyBzaWduYWwgY291bnQgYW5kIHJlc2V0IGl0LgogICogICAgICBTeW50YXg6CiAgKiAgICAgIGludCAgTW94YVBvcnRSZXNldEJya0NudChpbnQgcG9ydCk7CkBAIC0yMDkyLDI1ICsxOTQ2LDYgQEAKICAqICAgICAgICAgICByZXR1cm46ICAgIDAgLSAuLiAgOiBCUkVBSyBzaWduYWwgY291bnQKICAqCiAgKgotICogICAgICBGdW5jdGlvbiAzMjogICAgU2V0IHRoZSBTL1cgZmxvdyBjb250cm9sIG5ldyBYT04vWE9GRiB2YWx1ZSwgZGVmYXVsdAotICogICAgICAgICAgICAgICAgICAgICAgWE9OIGlzIDB4MTEgJiBYT0ZGIGlzIDB4MTMuCi0gKiAgICAgIFN5bnRheDoKLSAqICAgICAgdm9pZCBNb3hhUG9ydFNldFhvblhvZmYoaW50IHBvcnQsIGludCB4b25WYWx1ZSwgaW50IHhvZmZWYWx1ZSk7Ci0gKiAgICAgICAgICAgaW50IHBvcnQgICAgICAgICAgIDogcG9ydCBudW1iZXIgKDAgLSAxMjcpCi0gKiAgICAgICAgICAgaW50IHhvblZhbHVlICAgICAgIDogbmV3IFhPTiB2YWx1ZSAoMCAtIDI1NSkKLSAqICAgICAgICAgICBpbnQgeG9mZlZhbHVlICAgICAgOiBuZXcgWE9GRiB2YWx1ZSAoMCAtIDI1NSkKLSAqCi0gKgotICogICAgICBGdW5jdGlvbiAzMzogICAgQ2hlY2sgdGhpcyBwb3J0J3MgdHJhbnNtaXNzaW9uIGlzIGhvbGQgYnkgcmVtb3RlIHNpdGUKLSAqICAgICAgICAgICAgICAgICAgICAgIGJlY2F1c2UgdGhlIGZsb3cgY29udHJvbC4KLSAqICAgICAgU3ludGF4OgotICogICAgICBpbnQgIE1veGFQb3J0SXNUeEhvbGQoaW50IHBvcnQpOwotICogICAgICAgICAgIGludCBwb3J0ICAgICAgICAgICA6IHBvcnQgbnVtYmVyICgwIC0gMTI3KQotICoKLSAqICAgICAgICAgICByZXR1cm46ICAgIDAgICAgICAgOiBub3JtYWwKLSAqICAgICAgICAgICAgICAgICAgICAgIDEgICAgICAgOiBob2xkIGJ5IHJlbW90ZSBzaXRlCi0gKgotICoKICAqICAgICAgRnVuY3Rpb24gMzQ6ICAgIFNlbmQgb3V0IGEgQlJFQUsgc2lnbmFsLgogICogICAgICBTeW50YXg6CiAgKiAgICAgIHZvaWQgTW94YVBvcnRTZW5kQnJlYWsoaW50IHB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iJTAyeCAiLGJsb2NrW2kral0pOwotICAgICAgfQotICAgICAgbGluZWJ1ZlszKmpdPSdcMCc7Ci0gICAgICBUUkFDRV9QUygiJXMiLGxpbmVidWYpOwotICAgfQorCXVuc2lnbmVkIGludCBpLCBqOworCWNoYXIgbGluZWJ1ZlsxNiAqIDMgKyAxXTsKKworCWZvciAoaSA9IDA7IGkgPCBsZW5ndGg7IGkgKz0gMTYpIHsKKwkJZm9yIChqID0gMDsgKGogPCAxNikgJiYgKGogKyBpIDwgbGVuZ3RoKTsgaisrKSB7CisJCQlzcHJpbnRmKGxpbmVidWYgKyAzICogaiwgIiUwMnggIiwgYmxvY2tbaSArIGpdKTsKKwkJfQorCQlsaW5lYnVmWzMgKiBqXSA9ICdcMCc7CisJCVRSQUNFX1BTKCIlcyIsIGxpbmVidWYpOworCX0KIH0KIAotICAgICAgICAgCi0KLQogLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioKICAqIERyaXZlciBpbml0aWFsaXNhdGlvbgogICoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiovCiAKLQogLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioKICAqIE1vZHVsZSBzdXBwb3J0IHJvdXRpbmVzCiAgKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKi8KIAogc3RhdGljIHZvaWQgX19leGl0IHIzOTY0X2V4aXQodm9pZCkKIHsKLSAgIGludCBzdGF0dXM7Ci0gICAKLSAgIFRSQUNFX00gKCJjbGVhbnVwX21vZHVsZSgpIik7CisJaW50IHN0YXR1czsKIAotICAgc3RhdHVzPXR0eV91bnJlZ2lzdGVyX2xkaXNjKE5fUjM5NjQpOwotICAgCi0gICBpZihzdGF0dXMhPTApCi0gICB7Ci0gICAgICBwcmludGso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HNlIGlmKGM9PVNUWCkKLSAgICAgICAgIHsKLSAgICAgICAgICAgIGlmKHBJbmZvLT5uUmV0cnk9PTApCi0gICAgICAgICAgICB7Ci0gICAgICAgICAgICAgICBUUkFDRV9QRSgiVFhfUkVRVUVTVCAtIGluaXQgY29uZmxpY3QiKTsKLSAgICAgICAgICAgICAgIGlmKHBJbmZvLT5wcmlvcml0eSA9PSBSMzk2NF9TTEFWRSkKLSAgICAgICAgICAgICAgIHsKLSAgICAgICAgICAgICAgICAgIGdvdG8gc3RhcnRfcmVjZWl2aW5nOwotICAgICAgICAgICAgICAgfQotICAgICAgICAgICAgfSAKLSAgICAgICAgICAgIGVsc2UgCi0gICAgICAgICAgICB7Ci0gICAgICAgICAgICAgICBUUkFDRV9QRSgiVFhfUkVRVUVTVCAtIHNlY29uZGFyeSBpbml0IGNvbmZsaWN0IT8iCi0gICAgICAgICAgICAgICAgICAgICAgICAiIFN3aXRjaGluZyB0byBTTEFWRSBtb2RlIGZvciBuZXh0IHJ4LiIpOwotICAgICAgICAgICAgICAgZ290byBzdGFydF9yZWNlaXZpbmc7Ci0gICAgICAgICAgICB9Ci0gICAgICAgICB9Ci0gICAgICAgICBlbHNlCi0gICAgICAgICB7Ci0gICAgICAgICAgICBUUkFDRV9QRSgiVFhfUkVRVUVTVCAtIGNoYXIgIT0gRExFOiAleCIsIGMpOwotICAgICAgICAgICAgcmV0cnlfdHJhbnNtaXQocEluZm8pOwotICAgICAgICAgfQotICAgICAgICAgYnJlYWs7Ci0gICAgICBjYXNlIFIzOTY0X1RSQU5TTUlUVElORzoKLSAgICAgICAgIGlmKGM9PU5BSykKLSAgICAgICAgIHsKLSAgICAgICAgICAgIFRSQUNFX1BFKCJUUkFOU01JVFRJTkcgLSBnb3QgTkFLIik7Ci0gICAgICAgICAgICByZXRyeV90cmFuc21pdChwSW5mbyk7Ci0gICAgICAgICB9Ci0gICAgICAgICBlbHNlCi0gICAgICAgICB7Ci0gICAgICAgICAgICBUUkFDRV9QRSgiVFJBTlNNSVRUSU5HIC0gZ290IGludmFsaWQgY2hhciIpOwotIAotICAgICAgICAgICAgcEluZm8tPnN0YXRlID0gUjM5NjRfV0FJVF9aVlpfQkVGT1JFX1RYX1JFVFJZOwotCSAgICBtb2RfdGltZXIoJnBJbmZvLT50bXIsIGppZmZpZXMgKyBSMzk2NF9UT19aVlopOwotICAgICAgICAgfQotICAgICAgICAgYnJlYWs7Ci0gICAgICBjYXNlIFIzOTY0X1dBSVRfRk9SX1RYX0FDSzoKLSAgICAgICAgIGlmKGM9PURMRSkKLSAgICAgICAgIHsKLSAgICAgICAgICAgIFRSQUNFX1BTKCJXQUlUX0ZPUl9UWF9BQ0sgLSBnb3QgRExFIik7Ci0gICAgICAgICAgICByZW1vdmVfZnJvbV90eF9xdWV1ZShwSW5mbywgUjM5NjRfT0spOwotICAgICAgICAgICAgCi0gICAgICAgICAgICBwSW5mby0+c3RhdGUgPSBSMzk2NF9JRExFOwotICAgICAgICAgICAgdHJpZ2dlcl90cmFuc21pdChwSW5mbyk7Ci0gICAgICAgICB9Ci0gICAgICAgICBlbHNlCi0gICAgICAgICB7Ci0gICAgICAgICAgICByZXRyeV90cmFuc21pdChwSW5mbyk7Ci0gICAgICAgICB9Ci0gICAgICAgICBicmVhazsKLSAgICAgIGNhc2UgUjM5NjRfV0FJVF9GT1JfUlhfUkVQRUFUOgotICAgICAgICAgLyogRkFMTFRST1VHSCAqLwotICAgICAgY2FzZSBSMzk2NF9JRExFOgotICAgICAgICAgaWYoYz09U1RYKQotICAgICAgICAgewotICAgICAgICAgICAgLyogUHJldmVudCByeF9xdWV1ZSBmcm9tIG92ZXJmbG93OiAqLwotICAgICAgICAgICAgaWYocEluZm8tPmJsb2Nrc19pbl9yeF9xdWV1ZSA+PSBSMzk2NF9NQVhfQkxPQ0tTX0lOX1JYX1FVRVVFKQotICAgICAgICAgICAgewotICAgICAgICAgICAgICAgVFJBQ0VfUEUoIklETEUgLSBnb3QgU1RYIGJ1dCBubyBzcGF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JCX0KIHN0YXJ0X3JlY2VpdmluZzoKLSAgICAgICAgICAgIC8qIE9rLCBzdGFydCByZWNlaXZpbmc6ICovCi0gICAgICAgICAgICBUUkFDRV9QUygiSURMRSAtIGdvdCBTVFgiKTsKLSAgICAgICAgICAgIHBJbmZvLT5yeF9wb3NpdGlvbiA9IDA7Ci0gICAgICAgICAgICBwSW5mby0+bGFzdF9yeCA9IDA7Ci0gICAgICAgICAgICBwSW5mby0+ZmxhZ3MgJj0gflIzOTY0X0VSUk9SOwotICAgICAgICAgICAgcEluZm8tPnN0YXRlPVIzOTY0X1JFQ0VJVklORzsKLQkgICAgbW9kX3RpbWVyKCZwSW5mby0+dG1yLCBqaWZmaWVzICsgUjM5NjRfVE9fWlZaKTsKLQkgICAgcEluZm8tPm5SZXRyeSA9IDA7Ci0gICAgICAgICAgICBwdXRfY2hhcihwSW5mbywgRExFKTsKLSAgICAgICAgICAgIGZsdXNoKHBJbmZvKTsKLSAgICAgICAgICAgIHBJbmZvLT5iY2MgPSAwOwotICAgICAgICAgfQotICAgICAgICAgYnJlYWs7Ci0gICAgICBjYXNlIFIzOTY0X1JFQ0VJVklORzoKLSAgICAgICAgIGlmKHBJbmZvLT5yeF9wb3NpdGlvbiA8IFJYX0JVRl9TSVpFKQotICAgICAgICAgewotICAgICAgICAgICAgcEluZm8tPmJjYyBePSBjOwotICAgICAgICAgICAgCi0gICAgICAgICAgICBpZihjPT1ETEUpCi0gICAgICAgICAgICB7Ci0gICAgICAgICAgICAgICBpZihwSW5mby0+bGFzdF9yeD09RExFKQotICAgICAgICAgICAgICAgewotICAgICAgICAgICAgICAgICAgcEluZm8tPmxhc3RfcnggPSAwOwotICAgICAgICAgICAgICAgICAgZ290byBjaGFyX3RvX2J1ZjsKLSAgICAgICAgICAgICAgIH0KLSAgICAgICAgICAgICAgIHBJbmZvLT5sYXN0X3J4ID0gRExFOwotICAgICAgICAgICAgICAgYnJlYWs7Ci0gICAgICAgICAgICB9IAotICAgICAgICAgICAgZW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QtPnBpZCA9PSBwaWQpCi0gICAgICB7Ci0gICAgICAgICByZXR1cm4gcENsaWVudDsKLSAgICAgIH0KLSAgIH0KLSAgIHJldHVybiBOVUxMOworCXN0cnVjdCByMzk2NF9jbGllbnRfaW5mbyAqcENsaWVudDsKKworCWZvciAocENsaWVudCA9IHBJbmZvLT5maXJzdENsaWVudDsgcENsaWVudDsgcENsaWVudCA9IHBDbGllbnQtPm5leHQpIHsKKwkJaWYgKHBDbGllbnQtPnBpZCA9PSBwaWQpIHsKKwkJCXJldHVybiBwQ2xpZW50OworCQl9CisJfQorCXJldHVybiBOVUxMOwogfQogCiBzdGF0aWMgaW50IGVuYWJsZV9zaWduYWxzKHN0cnVjdCByMzk2NF9pbmZvICpwSW5mbywgc3RydWN0IHBpZCAqcGlkLCBpbnQgYXJnKQogewotICAgc3RydWN0IHIzOTY0X2NsaWVudF9pbmZvICpwQ2xpZW50OwotICAgc3RydWN0IHIzOTY0X2NsaWVudF9pbmZvICoqcHBDbGllbnQ7Ci0gICBzdHJ1Y3QgcjM5NjRfbWVzc2FnZSAqcE1zZzsKLSAgIAotICAgaWYoKGFyZyAmIFIzOTY0X1NJR19BTEwpPT0wKQotICAgewotICAgICAgLyogUmVtb3ZlIGNsaWVudCBmcm9tIGNsaWVudCBsaXN0ICovCi0gICAgICBmb3IocHBDbGllbnQ9JnBJbmZvLT5maXJzdENsaWVudDsgKnBwQ2xpZW50OyBwcENsaWVudD0mKCpwcENsaWVudCktPm5leHQpCi0gICAgICB7Ci0gICAgICAgICBwQ2xpZW50ID0gKnBwQ2xpZW50OwotICAgICAgICAgCi0gICAgICAgICBpZihwQ2xpZW50LT5waWQgPT0gcGlkKQotICAgICAgICAgewotICAgICAgICAgICAgVFJBQ0VfUFMoInJlbW92aW5nIGNsaWVudCAlZCBmcm9tIGNsaWVudCBsaXN0IiwgcGlkX25yKHBpZCkpOwotICAgICAgICAgICAgKnBwQ2xpZW50ID0gcENsaWVudC0+bmV4dDsKLSAgICAgICAgICAgIHdoaWxlKHBDbGllbnQtPm1zZ19jb3VudCkKLSAgICAgICAgICAgIHsKLSAgICAgICAgICAgICAgIHBNc2c9cmVtb3ZlX21zZyhwSW5mbywgcENsaWVudCk7Ci0gICAgICAgICAgICAgICBpZihwTXNnKQotICAgICAgICAgICAgICAgewotICAgICAgICAgICAgICAgICAga2ZyZWUocE1zZyk7Ci0gICAgICAgICAgICAgICAgICBUUkFDRV9NKCJlbmFibGVfc2lnbmFscyAtIG1zZyBrZnJlZSAlcCIscE1zZyk7Ci0gICAgICAgICAgICAgICB9Ci0gICAgICAgICAgICB9Ci0JICAgIHB1dF9waWQocENsaWVudC0+cGlkKTsKLSAgICAgICAgICAgIGtmcmVlKHBDbGllbnQpOwotICAgICAgICAgICAgVFJBQ0VfTSgiZW5hYmxlX3NpZ25hbHMgLSBrZnJlZSAlcCIscENsaWVudCk7Ci0gICAgICAgICAgICByZXR1cm4gMDsKLSAgICAgICAgIH0KLSAgICAgIH0KLSAgICAgIHJldHVybiAtRUlOVkFMOwotICAgfQotICAgZWxzZQotICAgewotICAgICAgcENsaWVudD1maW5kQ2xpZW50KHBJbmZvLCBwaWQpOwotICAgICAgaWYocENsaWVudCkKLSAgICAgIHsKLSAgICAgICAgIC8qIHVwZGF0ZSBzaWduYWwgb3B0aW9ucyAqLwotICAgICAgICAgcENsaWVudC0+c2lnX2ZsYWdzPWFyZzsKLSAgICAgIH0gCi0gICAgICBlbHNlIAotICAgICAgewotICAgICAgICAgLyogYWRkIGNsaWVudCB0byBjbGllbnQgbGlzdCAqLwotICAgICAgICAgcENsaWVudD1rbWFsbG9jKHNpemVvZihzdHJ1Y3QgcjM5NjRfY2xpZW50X2luZm8pLCBHRlBfS0VSTkVMKTsKLSAgICAgICAgIFRSQUNFX00oImVuYWJsZV9zaWduYWxzIC0ga21hbGxvYyAlcCIscENsaWVudCk7Ci0gICAgICAgICBpZihwQ2xpZW50PT1OVUxMKQotICAgICAgICAgICAgcmV0dXJuIC1FTk9NRU07C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ktPm5hbWUsICJjeV9vcGVuIikpewotICAgICAgICByZXR1cm4gLUVOT0RFVjsKLSAgICB9CisJaWYgKHNlcmlhbF9wYXJhbm9pYV9jaGVjayhpbmZvLCB0dHktPm5hbWUsICJjeV9vcGVuIikpIHsKKwkJcmV0dXJuIC1FTk9ERVY7CisJfQogI2lmZGVmIFNFUklBTF9ERUJVR19PUEVOCi0gICAgcHJpbnRrKCJjeV9vcGVuICVzLCBjb3VudCA9ICVkXG4iLCB0dHktPm5hbWUsIGluZm8tPmNvdW50KTsvKiovCisJcHJpbnRrKCJjeV9vcGVuICVzLCBjb3VudCA9ICVkXG4iLCB0dHktPm5hbWUsIGluZm8tPmNvdW50KTsKKwkvKiovCiAjZW5kaWYKLSAgICBpbmZvLT5jb3VudCsrOworCSAgICBpbmZvLT5jb3VudCsrOwogI2lmZGVmIFNFUklBTF9ERUJVR19DT1VOVAotICAgIHByaW50aygiY3ljOiAlZDogaW5jcmVtZW50aW5nIGNvdW50IHRvICVkXG4iLCBfX0xJTkVfXywgaW5mby0+Y291bnQpOworCXByaW50aygiY3ljOiAlZDogaW5jcmVtZW50aW5nIGNvdW50IHRvICVkXG4iLCBfX0xJTkVfXywgaW5mby0+Y291bnQpOwogI2VuZGlmCi0gICAgdHR5LT5kcml2ZXJfZGF0YSA9IGluZm87Ci0gICAgaW5mby0+dHR5ID0gdHR5OworCXR0eS0+ZHJpdmVyX2RhdGEgPSBpbmZvOworCWluZm8tPnR0eSA9IHR0eTsKIAotICAgIC8qCi0gICAgICogU3RhcnQgdXAgc2VyaWFsIHBvcnQKLSAgICAgKi8KLSAgICByZXR2YWwgPSBzdGFydHVwKGluZm8pOwotICAgIGlmIChyZXR2YWwpewotCXJldHVybiByZXR2YWw7Ci0gICAgfQorCS8qCisJICogU3RhcnQgdXAgc2VyaWFsIHBvcnQKKwkgKi8KKwlyZXR2YWwgPSBzdGFydHVwKGluZm8pOworCWlmIChyZXR2YWwpIHsKKwkJcmV0dXJuIHJldHZhbDsKK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AgICBjaGlwX2lkICAgIG1hbl9pZAotICAgIHc4MzYyN2VoZiAgIDEwICAgICAgNSAgICAgICA0ICAgICAgIDMgICAgICAgMHg4OCwweGExICAweDVjYTMKKyAgICBDaGlwICAgICAgICAjdmluICAgICNmYW4gICAgI3B3bSAgICAjdGVtcCAgY2hpcCBJRHMgICAgICAgbWFuIElECisgICAgdzgzNjI3ZWhmICAgMTAgICAgICA1ICAgICAgIDQgICAgICAgMyAgICAgIDB4ODg1MCAweDg4ICAgIDB4NWNhMworICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAweDg4NjAgMHhhMQorICAgIHc4MzYyN2RoZyAgICA5ICAgICAgNSAgICAgICA0ICAgICAgIDMgICAgICAweGEwMjAgMHhjMSAgICAweDVjYTMKICovCiAKICNpbmNsdWRlIDxsaW51eC9tb2R1bGUuaD4KQEAgLTU1LDggKzU3LDE4IEBACiAgKiBTdXBlci1JL08gY29uc3RhbnRzIGFuZCBmdW5jdGlvbnMKICAqLwogCisvKgorICogVGhlIHRocmVlIGZvbGxvd2luZyBnbG9iYWxzIGFyZSBpbml0aWFsaXplZCBpbiB3ODM2MjdlaGZfZmluZCgpLCBiZWZvcmUKKyAqIHRoZSBpMmMtaXNhIGRldmljZSBpcyBjcmVhdGVkLiBPdGhlcndpc2UsIHRoZXkgY291bGQgYmUgc3RvcmVkIGluCisgKiB3ODM2MjdlaGZfZGF0YS4gVGhpcyBpcyB1Z2x5LCBidXQgbmVjZXNzYXJ5LCBhbmQgd2hlbiB0aGUgZHJpdmVyIGlzIG5leHQKKyAqIHVwZGF0ZWQgdG8gYmVjb21lIGEgcGxhdGZvcm0gZHJpdmVyLCB0aGUgZ2xvYmFscyB3aWxsIGRpc2FwcGVhci4KKyAqLwogc3RhdGljIGludCBSRUc7CQkvKiBUaGUgcmVnaXN0ZXIgdG8gcmVhZC93cml0ZSAqLwogc3RhdGljIGludCBWQUw7CQkvKiBUaGUgdmFsdWUgdG8gcmVhZC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ZGVmaW5lIENRRV9XUklEX1dQVFIoeCkJKCh4KS51LnNjcWUud3JpZF9sb3cpCisKKy8qIGdlbmVyaWMgYWNjZXNzb3IgbWFjcm9zICovCisjZGVmaW5lIENRRV9XUklEX0hJKHgpCQkoKHgpLnUuc2NxZS53cmlkX2hpKQorI2RlZmluZSBDUUVfV1JJRF9MT1coeCkJCSgoeCkudS5zY3FlLndyaWRfbG93KQorCisjZGVmaW5lIFRQVF9FUlJfU1VDQ0VTUyAgICAgICAgICAgICAgICAgICAgIDB4MAorI2RlZmluZSBUUFRfRVJSX1NUQUcgICAgICAgICAgICAgICAgICAgICAgICAweDEJIC8qIFNUQUcgaW52YWxpZDogZWl0aGVyIHRoZSAqLworCQkJCQkJIC8qIFNUQUcgaXMgb2ZmbGltdCwgYmVpbmcgMCwgKi8KKwkJCQkJCSAvKiBvciBTVEFHX2tleSBtaXNtYXRjaCAqLworI2RlZmluZSBUUFRfRVJSX1BESUQgICAgICAgICAgICAgICAgICAgICAgICAweDIJIC8qIFBESUQgbWlzbWF0Y2ggKi8KKyNkZWZpbmUgVFBUX0VSUl9RUElEICAgICAgICAgICAgICAgICAgICAgICAgMHgzCSAvKiBRUElEIG1pc21hdGNoICovCisjZGVmaW5lIFRQVF9FUlJfQUNDRVNTICAgICAgICAgICAgICAgICAgICAgIDB4NAkgLyogSW52YWxpZCBhY2Nlc3MgcmlnaHQgKi8KKyNkZWZpbmUgVFBUX0VSUl9XUkFQICAgICAgICAgICAgICAgICAgICAgICAgMHg1CSAvKiBXcmFwIGVycm9yICovCisjZGVmaW5lIFRQVF9FUlJfQk9VTkQgICAgICAgICAgICAgICAgICAgICAgIDB4NgkgLyogYmFzZSBhbmQgYm91bmRzIHZvaWxhdGlvbiAqLworI2RlZmluZSBUUFRfRVJSX0lOVkFMSURBVEVfU0hBUkVEX01SICAgICAgICAweDcJIC8qIGF0dGVtcHQgdG8gaW52YWxpZGF0ZSBhICAqLworCQkJCQkJIC8qIHNoYXJlZCBtZW1vc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8qIHdyb25nIEREUCB2ZXJzaW9uICovCisjZGVmaW5lIFRQVF9FUlJfUkRNQV9WRVJTSU9OICAgICAgICAgICAgICAgIDB4MTUgLyogd3JvbmcgUkRNQSB2ZXJzaW9uICovCisjZGVmaW5lIFRQVF9FUlJfT1BDT0RFICAgICAgICAgICAgICAgICAgICAgIDB4MTYgLyogaW52YWxpZCByZG1hIG9wY29kZSAqLworI2RlZmluZSBUUFRfRVJSX0REUF9RVUVVRV9OVU0gICAgICAgICAgICAgICAweDE3IC8qIGludmFsaWQgZGRwIHF1ZXVlIG51bWJlciAqLworI2RlZmluZSBUUFRfRVJSX01TTiAgICAgICAgICAgICAgICAgICAgICAgICAweDE4IC8qIE1TTiBlcnJvciAqLworI2RlZmluZSBUUFRfRVJSX1RCSVQgICAgICAgICAgICAgICAgICAgICAgICAweDE5IC8qIHRhZyBiaXQgbm90IHNldCBjb3JyZWN0bHkgKi8KKyNkZWZpbmUgVFBUX0VSUl9NTyAgICAgICAgICAgICAgICAgICAgICAgICAgMHgxQSAvKiBNTyBub3QgMCBmb3IgVEVSTUlOQVRFICAqLworCQkJCQkJIC8qIG9yIFJFQURfUkVRICovCisjZGVmaW5lIFRQVF9FUlJfTVNOX0dBUCAgICAgICAgICAgICAgICAgICAgIDB4MUIKKyNkZWZpbmUgVFBUX0VSUl9NU05fUkFOR0UgICAgICAgICAgICAgICAgICAgMHgxQworI2RlZmluZSBUUFRfRVJSX0lSRF9PVkVSRkxPVyAgICAgICAgICAgICAgICAweDFECisjZGVmaW5lIFRQVF9FUlJfUlFFX0FERFJfQk9VTkQgICAgICAgICAgICAgIDB4MUUgLyogUlFFIGFkZHIgb3V0IG9mIGJvdW5kczogICovCisJCQkJCQkgLyogc29mdHdhcmUgZXJyb3IgKi8KKyNkZWZpbmUgVFBUX0VSUl9JTlRFUk5BTF9FUlIgICAgICAgICAgICAgICAgMHgxRiAvKiBpbnRlcm5hbCBlcnJvciAob3Bjb2RlICAqLworCQkJCQkJIC8qIG1p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MiBwYWdlX3NpemU6NTsKKworCXUzMiBwZGlkOworCXUzMiBxcGlkOworCXUzMiBwYmxfYWRkcjsKKwl1MzIgbGVuOworCXU2NCB2YV9mYm87CisJdTMyIHBibF9zaXplOworfTsKKworc3RydWN0IGl3Y2hfbXIgeworCXN0cnVjdCBpYl9tciBpYm1yOworCXN0cnVjdCBpd2NoX2RldiAqcmhwOworCXU2NCBrdmE7CisJc3RydWN0IHRwdF9hdHRyaWJ1dGVzIGF0dHI7Cit9OworCit0eXBlZGVmIHN0cnVjdCBpd2NoX213IGl3Y2hfbXdfaGFuZGxlOworCitzdGF0aWMgaW5saW5lIHN0cnVjdCBpd2NoX21yICp0b19pd2NoX21yKHN0cnVjdCBpYl9tciAqaWJtcikKK3sKKwlyZXR1cm4gY29udGFpbmVyX29mKGlibXIsIHN0cnVjdCBpd2NoX21yLCBpYm1yKTsKK30KKworc3RydWN0IGl3Y2hfbXcgeworCXN0cnVjdCBpYl9tdyBpYm13OworCXN0cnVjdCBpd2NoX2RldiAqcmhwOworCXU2NCBrdmE7CisJc3RydWN0IHRwdF9hdHRyaWJ1dGVzIGF0dHI7Cit9OworCitzdGF0aWMgaW5saW5lIHN0cnVjdCBpd2NoX213ICp0b19pd2NoX213KHN0cnVjdCBpYl9tdyAqaWJtdykKK3sKKwlyZXR1cm4gY29udGFpbmVyX29mKGlibXcsIHN0cnVjdCBpd2NoX213LCBpYm13KTsKK30KKworc3RydWN0IGl3Y2hfY3EgeworCXN0cnVjdCBpYl9jcSBpYmNxOworCXN0cnVjdCBpd2NoX2RldiAqcmhwOworCXN0cnVjdCB0M19jcSBjcTsKKwlzcGlubG9ja190IGxvY2s7CisJYXRvbWljX3QgcmVmY250OworCXdhaXRfcXVldWVfaGVhZF90IHdhaXQ7CisJdTMyIF9fdXNlciAqdXNlcl9ycHRyX2FkZHI7Cit9OworCitzdGF0aWMgaW5saW5lIHN0cnVjdCBpd2NoX2NxICp0b19pd2NoX2NxKHN0cnVjdCBpYl9jcSA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ZGV2aWNlICpkZXYsIHN0cnVjdCBpYl93YyAqd2MpOworI2Vsc2UKKworc3RydWN0IGlwb2liX2NtX3R4OworCitzdGF0aWMgaW5saW5lIGludCBpcG9pYl9jbV9hZG1pbl9lbmFibGVkKHN0cnVjdCBuZXRfZGV2aWNlICpkZXYpCit7CisJcmV0dXJuIDA7Cit9CitzdGF0aWMgaW5saW5lIGludCBpcG9pYl9jbV9lbmFibGVkKHN0cnVjdCBuZXRfZGV2aWNlICpkZXYsIHN0cnVjdCBuZWlnaGJvdXIgKm4pCisKK3sKKwlyZXR1cm4gMDsKK30KKworc3RhdGljIGlubGluZSBpbnQgaXBvaWJfY21fdXAoc3RydWN0IGlwb2liX25laWdoICpuZWlnaCkKKworeworCXJldHVybiAwOworfQorCitzdGF0aWMgaW5saW5lIHN0cnVjdCBpcG9pYl9jbV90eCAqaXBvaWJfY21fZ2V0KHN0cnVjdCBpcG9pYl9uZWlnaCAqbmVpZ2gpCit7CisJcmV0dXJuIE5VTEw7Cit9CisKK3N0YXRpYyBpbmxpbmUgdm9pZCBpcG9pYl9jbV9zZXQoc3RydWN0IGlwb2liX25laWdoICpuZWlnaCwgc3RydWN0IGlwb2liX2NtX3R4ICp0eCkKK3sKK30KKworc3RhdGljIGlubGluZQordm9pZCBpcG9pYl9jbV9zZW5kKHN0cnVjdCBuZXRfZGV2aWNlICpkZXYsIHN0cnVjdCBza19idWZmICpza2IsIHN0cnVjdCBpcG9pYl9jbV90eCAqdHgpCit7CisJcmV0dXJuOworfQorCitzdGF0aWMgaW5saW5lCitpbnQgaXBvaWJfY21fZGV2X29wZW4oc3RydWN0IG5ldF9kZXZpY2UgKmRldikKK3sKKwlyZXR1cm4gMDsKK30KKworc3RhdGljIGlubGluZQordm9pZCBpcG9pYl9jbV9kZXZfc3RvcChzdHJ1Y3QgbmV0X2RldmljZSAqZGV2KQoreworCXJldHVybjsKK30KKworc3RhdGljIGlubGluZQoraW50IGlwb2liX2NtX2Rldl9pbml0KHN0cnVjd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WVzdCAoWERJX0FfTlIoYSksIHRoaXMtPklkLCB0aGlzLT5SZXFDaCwgdGhpcy0+TUluZCwKICAgICAgICAgICAgICAgICAgICAgICAgICAgYS0+SWRUeXBlVGFibGVbdGhpcy0+Tm9dKTsKICAgICAgICAgYS0+cmFtX291dChhLCAmUmVxT3V0LT5SZXEsIHRoaXMtPk1JbmQpOwotICAgICAgICBtb3JlID0gVFJVRTsKKyAgICAgICAgbW9yZSA9IHRydWU7CiAgICAgICB9CiAgICAgICBlbHNlIHsKICAgICAgICAgeGRpX3hsb2dfcmVxdWVzdCAoWERJX0FfTlIoYSksIHRoaXMtPklkLCB0aGlzLT5SZXFDaCwgdGhpcy0+UmVxLAogICAgICAgICAgICAgICAgICAgICAgICAgICBhLT5JZFR5cGVUYWJsZVt0aGlzLT5Ob10pOwogICAgICAgICB0aGlzLT5Nb3JlIHw9WE1PUkVGOwogICAgICAgICBhLT5yYW1fb3V0KGEsICZSZXFPdXQtPlJlcSwgdGhpcy0+UmVxKTsKLSAgICAgICAgbW9yZSA9IEZBTFNFOworICAgICAgICBtb3JlID0gZmFsc2U7CiAgICAgICAgIGlmIChhLT5GbG93Q29udHJvbElkVGFibGVbdGhpcy0+UmVxQ2hdID09IHRoaXMtPklkKQotICAgICAgICAgIGEtPkZsb3dDb250cm9sU2tpcFRhYmxlW3RoaXMtPlJlcUNoXSA9IFRSVUU7CisgICAgICAgICAgYS0+Rmxvd0NvbnRyb2xTa2lwVGFibGVbdGhpcy0+UmVxQ2hdID0gdHJ1ZTsKICAgICAgICAgLyoKICAgICAgICAgICAgTm90ZSB0aGF0IHJlbW92ZSByZXF1ZXN0IHdhcyBzZW50IHRvIHRoZSBjYXJkCiAgICAgICAgICAgICovCkBAIC0zMTEsNyArMzExLDcgQEAKICAgICAgICAgLyogYXJlIG1hcmtlZCBSTlIgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKi8KICAgICAgIGlmKFJOUklkICYmIFJOUklkPT1hLT5yYW1faW4oYSwgJkluZEluLT5JbmRJZCkpIHsKICAgICAgICAgYS0+cmFtX291dChhLCAmSW5kSW4tPkluZCwgMCk7Ci0gICAgICAgIGEtPnJhbV9vdXQoYSwgJkluZEluLT5STlIsIFRSVUUpOworICAgICAgICBhLT5yYW1fb3V0KGEsICZJbmRJbi0+Uk5SLCB0cnVlKTsKICAgICAgIH0KICAgICAgIGVsc2UgewogICAgICAgICBJbmQgPSBhLT5yYW1faW4oYSwgJkluZEluLT5JbmQpOwpAQCAtMzMxLDcgKzMzMSw3IEBACiAgICAgICAgICAgICBkdHJjKGRwcmludGYoIlJOUiIpKTsKICAgICAgICAgICAgIGEtPnJhbV9vdXQoYSwgJkluZEluLT5JbmQsIDApOwogICAgICAgICAgICAgUk5SSWQgPSBhLT5yYW1faW4oYSwgJkluZEluLT5JbmRJZCk7Ci0gICAgICAgICAgICBhLT5yYW1fb3V0KGEsICZJbmRJbi0+Uk5SLCBUUlVFKTsKKyAgICAgICAgICAgIGEtPnJhbV9vdXQoYSwgJkluZEluLT5STlIsIHRydWUpOwogICAgICAgICAgIH0KICAgICAgICAgfQogICAgICAgfQpAQCAtMzQwLDcgKzM0MCw3IEBACiAgICAgfQogICAgIGEtPnJhbV9vdXQoYSwgJlBSX1JBTS0+SW5kT3V0cHV0LCAwKTsKICAgfQotICByZXR1cm4gRkFMU0U7CisgIHJldHVybiBmYWxzZTsKIH0KIGJ5dGUgc2NvbV90ZXN0X2ludChBREFQVEVSICogYSkKIHsKQEAgLTM5OSw3ICszOTksNyBAQAogICAgICAgICAgIHJldHVybiAoMCk7CiAgICAgICAgIH0KICAgICAgICAgaWYgKGV4dGVuZGVkX2luZm9fdHlwZSA9PSBESVZBX1JDX1RZUEVfUkVNT1ZFX0NPTVBMRVRFKQotICAgICAgICAgIGEtPlJjRXh0ZW5zaW9uU3VwcG9ydGVkID0gVFJVRTsKKyAgICAgICAgICBhLT5SY0V4dGVuc2lvblN1cHBvcnRlZCA9IHRydWU7CiAgICA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GMgPSBUUlVFOworICAgICAgICAgIGMgPSB0cnVlOwogICAgICAgfQogICAgICAgaWYgKG1zZy0+aGVhZGVyLmNvbW1hbmQgPT0gX0RBVEFfQjNfUikKICAgICAgIHsKQEAgLTUwNiwxMyArNTA2LDEzIEBACiAKICAgICAgICAgICAgIHJldHVybiBfUVVFVUVfRlVMTDsKICAgICAgICAgICB9Ci0gICAgICAgICAgYyA9IFRSVUU7CisgICAgICAgICAgYyA9IHRydWU7CiAgICAgICAgIH0KICAgICAgIH0KICAgICAgIGVsc2UKICAgICAgIHsKICAgICAgICAgaWYgKHBsY2ktPnJlcV9pbiB8fCBwbGNpLT5pbnRlcm5hbF9jb21tYW5kKQotICAgICAgICAgIGMgPSBUUlVFOworICAgICAgICAgIGMgPSB0cnVlOwogICAgICAgICBlbHNlCiAgICAgICAgIHsKICAgICAgICAgICBwbGNpLT5jb21tYW5kID0gbXNnLT5oZWFkZXIuY29tbWFuZDsKQEAgLTYyNiwxMCArNjI2LDEwIEBACiAgICAgICBicmVhazsKICAgICB9CiAKLSAgICBpZihwPmxlbmd0aCkgcmV0dXJuIFRSVUU7CisgICAgaWYocD5sZW5ndGgpIHJldHVybiB0cnVlOwogICB9CiAgIGlmKHBhcm1zKSBwYXJtc1tpXS5pbmZvID0gTlVMTDsKLSAgcmV0dXJuIEZBTFNFOworICByZXR1cm4gZmFsc2U7CiB9CiAKIHZvaWQgYXBpX3NhdmVfbXNnKEFQSV9QQVJTRSAgICppbiwgYnl0ZSAqZm9ybWF0LCBBUElfU0FWRSAgICpvdXQpCkBAIC02ODcsNyArNjg3LDcgQEAKICAgd29yZCBqOwogCiAgIGlmKCFyZW1vdmVfc3RhcnRlZCkgewotICAgIHJlbW92ZV9zdGFydGVkID0gVFJVRTsKKyAgICByZW1vdmVfc3RhcnRlZCA9IHRydWU7CiAgICAgZm9yKGk9MDtpPG1heF9hZGFwdGVyO2krKykgewogICAgICAgaWYoYWRhcHRlcltpXS5yZXF1ZXN0KSB7CiAgICA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AgICAgLyogQi1jaGFubmVsIHVzZWQgZm9yIEIzIGNvbm5lY3Rpb25zIChjaD09MCksIG9yIG5vIEIgY2hhbm5lbCAgICAqLwpAQCAtMTM4MSw3ICsxMzgxLDcgQEAKICAgICAgICAgICAgIHBsY2ktPmNvbW1hbmQgPSAwOwogICAgICAgICAgICAgZGJ1ZygxLGRwcmludGYoIlNwb29mIikpOwogICAgICAgICAgICAgc2VuZF9yZXEocGxjaSk7Ci0gICAgICAgICAgICByZXR1cm4gRkFMU0U7CisgICAgICAgICAgICByZXR1cm4gZmFsc2U7CiAgICAgICAgICAgfQogICAgICAgICAgIGlmKGNoPT00KWFkZF9wKHBsY2ksQ0hJLHBfY2hpKTsKICAgICAgICAgICBhZGRfcyhwbGNpLENQTiwmcGFybXNbMV0pOwpAQCAtMTM5NSwxMSArMTM5NSwxMSBAQAogICAgICAgICAgICAgcGxjaS0+YXBwbCA9IGFwcGw7CiAgICAgICAgICAgICBzaWdfcmVxKHBsY2ksTElTVEVOX1JFUSwwKTsKICAgICAgICAgICAgIHNlbmRfcmVxKHBsY2kpOwotICAgICAgICAgICAgcmV0dXJuIEZBTFNFOworICAgICAgICAgICAgcmV0dXJuIGZhbHNlOwogICAgICAgICAgIH0KICAgICAgICAgfQogICAgICAgICBzZW5kX3JlcShwbGNpKTsKLSAgICAgICAgcmV0dXJuIEZBTFNFOworICAgICAgICByZXR1cm4gZmFsc2U7CiAgICAgICB9CiAgICAgICBwbGNpLT5JZCA9IDA7CiAgICAgfQpAQCAtMTU3MSw3ICsxNTcxLDcgQEAKIGJ5dGUgY29ubmVjdF9hX3Jlcyhkd29yZCBJZCwgd29yZCBOdW1iZXIsIERJVkFfQ0FQSV9BREFQVEVSICAgKiBhLCBQTENJICAgKiBwbGNpLCBBUFBMICAgKiBhcHBsLCBBUElfUEFSU0UgKiBtc2cpCiB7CiAgIGRidWcoMSxkcHJpbnRmKCJjb25uZWN0X2FfcmVzIikpOwotICByZXR1cm4gRkFMU0U7CisgIHJ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ICAgICBpZihwbGNpLT5TdGF0ZSAmJiBhaV9wYXJtc1syXS5sZW5ndGgpCkBAIC0xNzY5LDcgKzE3NjksNyBAQAogICAgIGlmKChpPWdldF9wbGNpKGEpKSkKICAgICB7CiAgICAgICByY19wbGNpID0gJmEtPnBsY2lbaS0xXTsKLSAgICAgIGFwcGwtPk51bGxDUkVuYWJsZSAgPSBUUlVFOworICAgICAgYXBwbC0+TnVsbENSRW5hYmxlICA9IHRydWU7CiAgICAgICByY19wbGNpLT5pbnRlcm5hbF9jb21tYW5kID0gQ19OQ1JfRkFDX1JFUTsKICAgICAgIHJjX3BsY2ktPmFwcGwgPSBhcHBsOwogICAgICAgYWRkX3AocmNfcGxjaSxDQUksIlx4MDFceDgwIik7CkBAIC0xNzg4LDcgKzE3ODgsNyBAQAogICAgICAgYWRkX2FpKHJjX3BsY2ksICZtc2dbMV0pOwogICAgICAgc2lnX3JlcShyY19wbGNpLE5DUl9GQUNJTElUWSwwKTsKICAgICAgIHNlbmRfcmVxKHJjX3BsY2kpOwotICAgICAgcmV0dXJuIEZBTFNFOworICAgICAgcmV0dXJuIGZhbHNlOwogICAgICAvKiBmb3IgYXBwbGljYXRpb24gY29udHJvbGxlZCBzdXBwbGVtZW50YXJ5IHNlcnZpY2VzICAgICovCiAgICAgfQogICB9CkBAIC0xODExLDEzICsxODExLDEzIEBACiAgICAgICAgICAgTnVtYmVyLAogICAgICAgICAgICJ3IixJbmZvKTsKICAgfQotICByZXR1cm4gRkFMU0U7CisgIHJldHVybiBmYWxzZTsKIH0KIAogYnl0ZSBpbmZvX3Jlcyhkd29yZCBJZCwgd29yZCBOdW1iZXIsIERJVkFfQ0FQSV9BREFQVEVSICAgKiBhLCBQTENJICAgKiBwbGNpLCBBUFBMICAgKiBhcHBsLCBBUElfUEFSU0UgKiBtc2cpCiB7CiAgIGRidWcoMSxkcHJpbnRmKCJpbmZvX3JlcyIpKTsKLSAgcmV0dXJuIEZBTFNFOworICByZXR1cm4gZmFsc2U7CiB9CiAKIGJ5dGUgYWxlcnRfcmVxKGR3b3JkIElkLCB3b3JkIE51bWJlciwgRElWQV9DQVBJX0FEQVBURVIgICAqIGEsIFBMQ0kgICAqIHBsY2ksIEFQUEwgICAqIGFwcGwsIEFQSV9QQVJTRSAqIG1zZykKQEAgLTE4MjgsNyArMTgyOCw3IEBACiAgIGRidWcoMSxkcHJpbnRmKCJhbGVydF9yZXEiKSk7CiAKICAgSW5mbyA9IF9XUk9OR19JREVOVElGSUVSOwotICByZXQgPSBGQUxTRTsKKyAgcmV0ID0gZmFsc2U7CiAgIGlmKHBsY2kpIHsKICAgICBJbmZvID0gX0FMRVJUX0lHTk9SRUQ7CiAgICAgaWYocGxjaS0+U3RhdGUhPUlOQ19DT05fQUxFUlQpIHsKQEAgLTE5MjIsNyArMTkyMiw3IEBACiAgICAgICAgICAgICBycGxjaS0+YXBwbCA9IGFwcGw7CiAgICAgICAgICAgICBzaWdfcmVxKHJwbGNpLFNfU1VQUE9SVEVELDApOwogICAgICAgICAgICAgc2VuZF9yZXEocnBsY2kpOwotICAgICAgICAgICAgcmV0dXJuIEZBTFNFOworICAgICAgICAgICAgcmV0dXJuIGZhbHNlOwogICAgICAgICAgICAgYnJlYWs7CiAKICAgICAgICAgICBjYXNlIFNfTElTVEVOOgpAQCAtMTk3Miw3ICsxOTcyLDcgQEAKICAgICAgICAgICAgICAgYWRkX3MocGxjaSxDQUksJnNzX3Bhcm1zWzFdKTsKICAgICAgICAgICAgICAgc2lnX3JlcShwbGNpLENBTExfSE9MRCwwKTsKICAgICAgICAgICAgICAgc2VuZF9yZXEocGxjaSk7Ci0gICAgICAgICAgICAgIHJldHVybiBGQUxTRTsKKyAgICAgICAgICAgICAgcmV0dXJuIGZhbHNlOwogICAgICAgICAgICAgfQogICAgICAgICAgICAgZWxzZSBJbmZvID0gMHgzMDEwOyAgICAgICAgICAgICAgICAgICAgLyogd3Jvbmcgc3RhdGUgICAgICAgICAgICovCiAgICAgICAgICAgICBicmVhazsKQEAgLTE5OTcsMTMgKzE5OTcsMTMgQEAKICAgICAgICAgICAgICAgICBwbGNpLT5pbnRlcm5hbF9jb21tYW5kID0gQkxPQ0tfUExDSTsKICAgICAgICAgICAgICAgICBwbGNpLT5jb21tYW5kID0gMDsKICAgICAgICAgICAgICAgICBkYnVnKDEsZHByaW50ZigiU3Bvb2YiKSk7Ci0gICAgICAgICAgICAgICAgcmV0dXJuIEZBTFNFOworICAgICAgICAgICAgICAgIHJldHVybiBmYWxzZTsKICAgICAgICAgICAgICAgfQogICAgICAgICAgICAgICBlbHNlCiAgICAgICAgICAgICAgIHsKICAgICAgICAgICAgICAgICBzaWdfcmVxKHBsY2ksQ0FMTF9SRVRSSUVWRSwwKTsKICAgICAgICAgICAgICAgICBzZW5kX3JlcShwbGNpKTsKLSAgICAgICAgICAgICAgICByZXR1cm4gRkFMU0U7CisgICAgICAgICAgICAgICAgcmV0dXJuIGZhbHNlOwogICAgICAgICAgICAgICB9CiAgICAgICAgICAgICB9CiAgICAgICAgICAgICBlbHNlIEluZm8gPSAweDMwMTA7ICAgICAgICAgICAgICAgICAgICAvKiB3cm9uZyBzdGF0ZSAgICAgICAgICAgKi8KQEAgLTIxMjMsNyArMjEyMyw3IEBACiAgICAgICAgICAgICAgIGFkZF9wKHBsY2ksQ0FJLGNhaSk7CiAgICAgICAgICAgICAgIHNpZ19yZXEocGxjaSxTX1NFUlZJQ0UsMCk7CiAgICAgICAgICAgICAgIHNlbmRfcmVxKHBsY2kpOwotICAgICAgICAgICAgICByZXR1cm4gRkFMU0U7CisgICAgICAgICAgICAgIHJldHVybiBmYWxzZTsKICAgICAgICAgICAgIH0KICAgICAgICAgICAgIGVsc2UgSW5mbyA9IDB4MzAxMDsgICAgICAgICAgICAgICAgICAgIC8qIHdyb25nIHN0YXRlICAgICAgICAgICAqLwogICAgICAgICAgICAgYnJlYWs7CkBAIC0yMjY1LDcgKzIyNjUsNyBAQAogICAgICAgICAgICAgICBhZGRfcChycGxjaSxDQUksY2FpKTsKICAgICAgICAgICAgICAgc2lnX3JlcShycGxjaSxTX1NFUlZJQ0UsMCk7CiAgICAgICAgICAgICAgIHNlbmRfcmVxKHJwbGNpKTsKLSAgICAgICAgICAgICAgcmV0dXJuIEZBTFNFOworICAgICAgICAgICAgICByZXR1cm4gZmFsc2U7CiAgICAgICAgICAgICB9CiAgICAgICAgICAgICBlbHNlCiAgICAgICAgICAgICB7CkBAIC0yMjkxLDE0ICsyMjkxLDE0IEBACiAgICAgICAgICAgICBzc19wYXJtc1szXS5pbmZvWzNdID0gKGJ5dGUpR0VUX1dPUkQoJihzc19wYXJtc1syXS5pbmZvWzBdKSk7CiAgICAgICAgICAgICBwbGNpLT5jb21tYW5kID0gMDsKICAgICAgICAgICAgIHBsY2ktPmludGVybmFsX2NvbW1hbmQgPSBDRF9SRVFfUEVORDsKLSAgICAgICAgICAgIGFwcGwtPkNERW5hYmxlID0gVFJVRTsKKyAgICAgICAgICAgIGFwcGwtPkNERW5hYmxlID0gdHJ1ZTsKICAgICAgICAgICAgIGNhaVswXSA9IDE7CiAgICAgICAgICAgICBjYWlbMV0gPSBDQUxMX0RFRkxFQ1RJT047CiAgICAgICAgICAgICBhZGRfcChwbGNpLENBSSxjYWkpOwogICAgICAgICAgICAgYWRkX3AocGxjaSxDUE4sc3NfcGFybXNbM10uaW5mbyk7CiAgICAgICAgICAgICBzaWdfcmVxKHBsY2ksU19TRVJWSUNFLDApOwogICAgICAgICAgICAgc2VuZF9yZXEocGxjaSk7Ci0gICAgICAgICAgICByZXR1cm4gRkFMU0U7CisgICAgICAgICAgICByZXR1cm4gZmFsc2U7CiAgICAgICAgICAgICBicmVhazsKIAogICAgICAgICAgIGNhc2UgU19DQUxMX0ZPUldBUkRJTkdfU1RBUlQ6CkBAIC0yMzM3LDcgKzIzMzcsNyBAQAogICAgICAgICAgICAgYWRkX3AocnBsY2ksQ1BOLHNzX3Bhcm1zWzZdLmluZm8pOwogICAgICAgICAgICAgc2lnX3JlcShycGxjaSxTX1NFUlZJQ0UsMCk7CiAgICAgICAgICAgICBzZW5kX3JlcShycGxjaSk7Ci0gICAgICAgICAgICByZXR1cm4gRkFMU0U7CisgICAgICAgICAgICByZXR1cm4gZmFsc2U7CiAgICAgICAgICAgICBicmVhazsKIAogICAgICAgICAgIGNhc2UgU19JTlRFUlJPR0FURV9ESVZFUlNJT046CkBAIC0yNDU2LDcgKzI0NTYsNyBAQAogICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICBzaWdfcmVxKHJwbGNpLFNfU0VSVklDRSwwKTsKICAgICAgICAgICAgIHNlbmRfcmVxKHJwbGNpKTsKLSAgICAgICAgICAgIHJldHVybiBGQUxTRTsKKyAgICAgICAgICAgIHJldHVybiBmYWxzZTsKICAgICAgICAgICAgIGJyZWFrOwogCiAgICAgICAgICAgY2FzZSBTX01XSV9BQ1RJVkFURToKQEAgLTI0NzIsNyArMjQ3Miw3IEBACiAgICAgICAgICAgICAgIHsKICAgICAgICAgICAgICAgICBycGxjaSA9ICZhLT5wbGNpW2ktMV07CiAgICAgICAgICAgICAgICAgcnBsY2ktPmFwcGwgPSBhcHBsOwotICAgICAgICAgICAgICAgIHJwbGNpLT5jcl9lbnF1aXJ5PVRSVUU7CisgICAgICAgICAgICAgICAgcnBsY2ktPmNyX2VucXVpcnk9dHJ1ZTsKICAgICAgICAgICAgICAgICBhZGRfcChycGxjaSxDQUksIlx4MDFceDgwIik7CiAgICAgICAgICAgICAgICAgYWRkX3AocnBsY2ksVUlELCJceDA2XHg0M1x4NjFceDcwXHg2OVx4MzJceDMwIik7CiAgICAgICAgICAgICAgICAgc2lnX3JlcShycGxjaSxBU1NJR04sRFNJR19JRCk7CkBAIC0yNDg3LDcgKzI0ODcsNyBAQAogICAgICAgICAgICAgZWxzZQogICAgICAgICAgICAgewogICAgICAgICAgICAgICBycGxjaSA9IHBsY2k7Ci0gICAgICAgICAgICAgIHJwbGNpLT5jcl9lbnF1aXJ5PUZBTFNFOworICAgICAgICAgICAgICBycGxjaS0+Y3JfZW5xdWlyeT1mYWxzZTsKICAgICAgICAgICAgIH0KIAogICAgICAgICAgICAgcnBsY2ktPmNvbW1hbmQgPSAwOwpAQCAtMjUwOSw3ICsyNTA5LDcgQEAKICAgICAgICAgICAgIGFkZF9wKHJwbGNpLFVJRCxzc19wYXJtc1sxMF0uaW5mbyk7IC8qIFRpbWUgKi8KICAgICAgICAgICAgIHNpZ19yZXEocnBsY2ksU19TRVJWSUNFLDApOwogICAgICAgICAgICAgc2VuZF9yZXEocnBsY2kpOwotICAgICAgICAgICAgcmV0dXJuIEZBTFNFOworICAgICAgICAgICAgcmV0dXJuIGZhbHNlOwogCiAgICAgICAgICAgY2FzZSBTX01XSV9ERUFDVElWQVRFOgogICAgICAgICAgICAgaWYoYXBpX3BhcnNlKCZwYXJtcy0+aW5mb1sxXSwod29yZClwYXJtcy0+bGVuZ3RoLCJ3Ynd3c3MiLHNzX3Bhcm1zKSkKQEAgLTI1MjQsNyArMjUyNCw3IEBACiAgICAgICAgICAgICAgIHsKICAgICAgICAgICAgICAgICBycGxjaSA9ICZhLT5wbGNpW2ktMV07CiAgICAgICAgICAgICAgICAgcnBsY2ktPmFwcGwgPSBhcHBsOwotICAgICAgICAgICAgICAgIHJwbGNpLT5jcl9lbnF1aXJ5PVRSVUU7CisgICAgICAgICAgICAgICAgcnBsY2ktPmNyX2VucXVpcnk9dHJ1ZTsKICAgICAgICAgICAgICAgICBhZGRfcChycGxjaSxDQUksIlx4MDFceDgwIik7CiAgICAgICAgICAgICAgICAgYWRkX3AocnBsY2ksVUlELCJceDA2XHg0M1x4NjFceDcwXHg2OVx4MzJceDMwIik7CiAgICAgICAgICAgICAgICAgc2lnX3JlcShycGxjaSxBU1NJR04sRFNJR19JRCk7CkBAIC0yNTM5LDcgKzI1MzksNyBAQAogICAgICAgICAgICAgZWxzZQogICAgICAgICAgICAgewogICAgICAgICAgICAgICBycGxjaSA9IHBsY2k7Ci0gICAgICAgICAgICAgIHJwbGNpLT5jcl9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m1zKQpAQCAtMjY0OSw3ICsyNjQ5LDcgQEAKICAgICAgICAgICAgICAgSWQsCiAgICAgICAgICAgICAgIE51bWJlciwKICAgICAgICAgICAgICAgInciLEluZm8pOwotICAgICAgICByZXR1cm4gRkFMU0U7CisgICAgICAgIHJldHVybiBmYWxzZTsKICAgICAgIH0KICAgICAgIHBsY2ktPnJlcXVlc3RlZF9vcHRpb25zX2Nvbm4gPSAwOwogCkBAIC0yNjg0LDcgKzI2ODQsNyBAQAogICAgICAgICAgICB8fCAoZmF4X2ZlYXR1cmVfYml0cyAmIFQzMF9GRUFUVVJFX0JJVF9NT1JFX0RPQ1VNRU5UUykpCiAgICAgICAgICAgewogICAgICAgICAgICAgbGVuID0gKGJ5dGUpKCYoKChUMzBfSU5GTyAqKSAwKS0+dW5pdmVyc2FsXzYpKTsKLSAgICAgICAgICAgIGZheF9pbmZvX2NoYW5nZSA9IEZBTFNFOworICAgICAgICAgICAgZmF4X2luZm9fY2hhbmdlID0gZmFsc2U7CiAgICAgICAgICAgICBpZiAobmNwaS0+bGVuZ3RoID49IDQpCiAgICAgICAgICAgICB7CiAgICAgICAgICAgICAgIHcgPSBHRVRfV09SRCgmbmNwaS0+aW5mb1szXSk7CkBAIC0yNjkzLDcgKzI2OTMsNyBAQAogICAgICAgICAgICAgICAgICgoVDMwX0lORk8gICAqKShwbGNpLT5mYXhfY29ubmVjdF9pbmZvX2J1ZmZlcikpLT5yZXNvbHV0aW9uID0KICAgICAgICAgICAgICAgICAgIChieXRlKSgoKChUMzBfSU5GTyAgICopKHBsY2ktPmZheF9jb25uZWN0X2luZm9fYnVmZmVyKSktPnJlc29sdXRpb24gJiB+VDMwX1JFU09MVVRJT05fUjhfMDc3MF9PUl8yMDApIHwKICAgICAgICAgICAgICAgICAgICgodyAmIDB4MDAwMSkgPyBUMzBfUkVTT0xVVElPTl9SOF8wNzcwX09SXzIwMCA6IDApKTsKLSAgICAgICAgICAgICAgICBmYXhfaW5mb19jaGFuZ2UgPSBUUlVFOworICAgICAgICAgICAgICAgIGZheF9pbmZvX2NoYW5nZSA9IHRydWU7CiAgICAgICAgICAgICAgIH0KICAgICAgICAgICAgICAgZmF4X2NvbnRyb2xfYml0cyAmPSB+KFQzMF9DT05UUk9MX0JJVF9SRVFVRVNUX1BPTExJTkcgfCBUMzBfQ09OVFJPTF9CSVRfTU9SRV9ET0NVTUVOVFMpOwogICAgICAgICAgICAgICBpZiAodyAmIDB4MDAwMikgIC8qIEZheC1wb2xsaW5nIHJlcXVlc3QgKi8KQEAgLTI3MDksNyArMjcwOSw3IEBACiAgICAgICAgICAgICAgICAgaWYgKCgoYnl0ZSkgdykgIT0gKChUMzBfSU5GTyAgICopKHBsY2ktPmZheF9jb25uZWN0X2luZm9fYnVmZmVyKSktPmRhdGFfZm9ybWF0KQogICAgICAgICAgICAgICAgIHsKICAgICAgICAgICAgICAgICAgICgoVDMwX0lORk8gICAqKShwbGNpLT5mYXhfY29ubmVjdF9pbmZvX2J1ZmZlcikpLT5kYXRhX2Zvcm1hdCA9IChieXRlKSB3OwotICAgICAgICAgICAgICAgICAgZmF4X2luZm9fY2hhbmdlID0gVFJVRTsKKyAgICAgICAgICAgICAgICAgIGZheF9pbmZvX2NoYW5nZSA9IHRydWU7CiAgICAgICAgICAgICAgICAgfQogCiAgICAgICAgICAgICAgICAgaWYgKChhLT5tYW5fcHJvZmlsZS5wcml2YXRlX29wdGlvbnMgJiAoMUwgPDwgUFJJVkFURV9GQVhfU1VCX1NFUF9QV0QpKQpAQCAtMjc4MSwxMyArMjc4MSwxMyBAQAogICAgICAgICAgICAgICAgIHsKICAgICAgICAgICAgICAgICAgIGxlbiA9IChieXRlKSgmKCgoVDMwX0lORk8gKikgMCktPnVuaXZlcnNhbF82KSk7CiAgICAgICAgICAgICAgICAgfQotICAgICAgICAgICAgICAgIGZheF9pbmZvX2NoYW5nZSA9IFRSVUU7CisgICAgICAgICAgICAgICAgZmF4X2luZm9fY2hhbmdlID0gdHJ1ZTsKIAogICAgICAgICAgICAgICB9CiAgICAgICAgICAgICAgIGlmIChmYXhfY29udHJvbF9iaXRzICE9IEdFVF9XT1JEKCYoKFQzMF9JTkZPICAgKilwbGNpLT5mYXhfY29ubmVjdF9pbmZvX2J1ZmZlciktPmNvbnRyb2xfYml0c19sb3cpKQogICAgICAgICAgICAgICB7CiAgICAgICAgICAgICAgICAgUFVUX1dPUkQgKCYoKFQzMF9JTkZPICAgKilwbGNpLT5mYXhfY29ubmVjdF9pbmZvX2J1ZmZlciktPmNvbnRyb2xfYml0c19sb3csIGZheF9jb250cm9sX2JpdHMpOwotICAgICAgICAgICAgICAgIGZheF9pbmZvX2NoYW5nZSA9IFRSVUU7CisgICAgICAgICAgICAgICAgZmF4X2luZm9fY2hhbmdlID0gdHJ1ZTsKICAgICAgICAgICAgICAgfQogICAgICAgICAgICAgfQogICAgICAgICAgICAgaWYgKEluZm8gPT0gR09PRCkKQEAgLTI3OTgsMTIgKzI3OTgsMTIgQEAKICAgICAgICAgICAgICAgICBpZiAoZmF4X2ZlYXR1cmVfYml0cyAmIFQzMF9GRUFUVVJFX0JJVF9NT1JFX0RPQ1VNRU5UUykKICAgICAgICAgICAgICAgICB7CiAgICAgICAgICAgICAgICAgICBzdGFydF9pbnRlcm5hbF9jb21tYW5kIChJZCwgcGxjaSwgZmF4X2Nvbm5lY3RfaW5mb19jb21tYW5kKTsKLSAgICAgICAgICAgICAgICAgIHJldHVybiBGQUxTRTsKKyAgICAgICAgICAgICAgICAgIHJldHVybiBmYWxzZTsKICAgICAgICAgICAgICAgICB9CiAgICAgICAgICAgICAgICAgZWxzZQogICAgICAgICAgICAgICAgIHsKICAgICAgICAgICAgICAgICAgIHN0YXJ0X2ludGVybmFsX2NvbW1hbmQgKElkLCBwbGNpLCBmYXhfYWRqdXN0X2IyM19jb21tYW5kKTsKLSAgICAgICAgICAgICAgICAgIHJldHVybiBGQUxTRTsKKyAgICAgICAgICAgICAgICAgIHJldHVybiBmYWxzZTsKICAgICAgICAgICAgICAgICB9CiAgICAgICAgICAgICAgIH0KICAgICAgICAgICAgIH0KQEAgLTI4MjAsNyArMjgyMCw3IEBACiAgICAgICAgIGZvciAodyA9IDA7IHcgPCBuY3BpLT5sZW5ndGg7IHcrKykKICAgICAgICAgICBwbGNpLT5pbnRlcm5hbF9yZXFfYnVmZmVyWzIrd10gPSBuY3BpLT5pbmZvWzErd107CiAgICAgICAgIHN0YXJ0X2ludGVybmFsX2NvbW1hbmQgKElkLCBwbGNpLCBydHBfY29ubmVjdF9iM19yZXFfY29tbWFuZCk7Ci0gICAgICAgIHJldHVybiBGQUxTRTsKKyAgICAgICAgcmV0dXJuIGZhbHNlOwogICAgICAgfQogCiAgICAgICBpZighSW5mbykKQEAgLTI4MzcsNyArMjgzNyw3IEBACiAgICAgICAgIElkLAogICAgICAgICBOdW1iZXIsCiAgICAgICAgICJ3IixJbmZvKTsKLSAgcmV0dXJuIEZBTFNFOworICByZXR1cm4gZmFsc2U7CiB9CiAKIGJ5dGUgY29ubmVjdF9iM19yZXMoZHdvcmQgSWQsIHdvcmQgTnVtYmVyLCBESVZBX0NBUElfQURBUFRFUiAgICogYSwgUExDSSAgICogcGxjaSwgQVBQTCAgICogYXBwbCwgQVBJX1BBUlNFICogcGFybXMpCkBAIC0yOTA5LDcgKzI5MDksNyBAQAogICAgICAgICAgICAgcGxjaS0+ZmF4X2Nvbm5lY3RfaW5mb19sZW5ndGggPSBsZW47CiAgICAgICAgICAgICAoKFQzMF9JTkZPICopKHBsY2ktPmZheF9jb25uZWN0X2luZm9fYnVmZmVyKSktPmNvZGUgPSAwOwogICAgICAgICAgICAgc3RhcnRfaW50ZXJuYWxfY29tbWFuZCAoSWQsIHBsY2ksIGZheF9jb25uZWN0X2Fja19jb21tYW5kKTsKLSAgICAgcmV0dXJuIEZBTFNFOworICAgICByZXR1cm4gZmFsc2U7CiAgICAgICAgICAgfQogICAgICAgICB9CiAKQEAgLTI5MzIsNyArMjkzMiw3IEBACiAgICAgICAgIGZvciAodyA9IDA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9iM19yZXEoZHdvcmQgSWQsIHdvcmQgTnVtYmVyLCBESVZBX0NBUElfQURBUFRFUiAgICogYSwgUExDSSAgICogcGxjaSwgQVBQTCAgICogYXBwbCwgQVBJX1BBUlNFICogcGFybXMpCkBAIC0zMDA0LDcgKzMwMDQsNyBAQAogICAgICAgewogICAgICAgICBwbGNpLT5zZW5kX2Rpc2MgPSAoYnl0ZSluY2NpOwogICAgICAgICBwbGNpLT5jb21tYW5kID0gMDsKLSAgICAgICAgcmV0dXJuIEZBTFNFOworICAgICAgICByZXR1cm4gZmFsc2U7CiAgICAgICB9CiAgICAgICBlbHNlCiAgICAgICB7CkBAIC0zMDI4LDcgKzMwMjgsNyBAQAogICAgICAgICBJZCwKICAgICAgICAgTnVtYmVyLAogICAgICAgICAidyIsSW5mbyk7Ci0gIHJldHVybiBGQUxTRTsKKyAgcmV0dXJuIGZhbHNlOwogfQogCiBieXRlIGRpc2Nvbm5lY3RfYjNfcmVzKGR3b3JkIElkLCB3b3JkIE51bWJlciwgRElWQV9DQVBJX0FEQVBURVIgICAqIGEsIFBMQ0kgICAqIHBsY2ksIEFQUEwgICAqIGFwcGwsIEFQSV9QQVJTRSAqIHBhcm1zKQpAQCAtMzA4NCw3ICszMDg0LDcgQEAKICAgICAgIH0KICAgICB9CiAgIH0KLSAgcmV0dXJuIEZBTFNFOworICByZXR1cm4gZmFsc2U7CiB9CiAKIGJ5dGUgZGF0YV9iM19yZXEoZHdvcmQgSWQsIHdvcmQgTnVtYmVyLCBESVZBX0NBUElfQURBUFRFUiAgICogYSwgUExDSSAgICogcGxjaSwgQVBQTCAgICogYXBwbCwgQVBJX1BBUlNFICogcGFybXMpCkBAIC0zMTQwLDcgKzMxNDAsNyBAQAogICAgICAgfQogCiAgICAgICBzZW5kX2RhdGEocGxjaSk7Ci0gICAgICByZXR1cm4gRkFMU0U7CisgICAgICByZXR1cm4gZmFsc2U7CiAgICAgfQogICB9CiAgIGlmIChhcHBsKQpAQCAtMzE2MSw3ICszM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nJlYWs7CiAgICAgfQogICB9Ci0gIHJldHVybiBGQUxTRTsKKyAgcmV0dXJuIGZhbHNlOwogfQogCiBieXRlIGNvbm5lY3RfYjNfdDkwX2FfcmVzKGR3b3JkIElkLCB3b3JkIE51bWJlciwgRElWQV9DQVBJX0FEQVBURVIgICAqIGEsIFBMQ0kgICAqIHBsY2ksIEFQUEwgICAqIGFwcGwsIEFQSV9QQVJTRSAqIHBhcm1zKQpAQCAtMzI5Miw3ICszMjkyLDcgQEAKICAgICAgIHJldHVybiAxOwogICAgIH0KICAgfQotICByZXR1cm4gRkFMU0U7CisgIHJldHVybiBmYWxzZTsKIH0KIAogCkBAIC0zMzc4LDcgKzMzNzgsNyBAQAogICAgICAgICAgICAgICBwbGNpLT5pbnRlcm5hbF9jb21tYW5kID0gQkxPQ0tfUExDSTsgLyogbG9jayBvdGhlciBjb21tYW5kcyAqLwogICAgICAgICAgICAgICBwbGNpLT5jb21tYW5kID0gMDsKICAgICAgICAgICAgICAgZGJ1ZygxLGRwcmludGYoImNvbnRpbnVlIGlmIGNvZGVjIGxvYWRlZCIpKTsKLSAgICAgICAgICAgICAgcmV0dXJuIEZBTFNFOworICAgICAgICAgICAgICByZXR1cm4gZmFsc2U7CiAgICAgICAgICAgICB9CiAgICAgICAgICAgfQogICAgICAgICB9CkBAIC0zNDA3LDEyICszNDA3LDEyIEBACiAgICAgICAgIGVsc2UgaWYgKHBsY2ktPmNhbGxfZGlyICYgQ0FMTF9ESVJfSU4pCiAgICAgICAgICAgcGxjaS0+Y2FsbF9kaXIgPSBDQUxMX0RJUl9JTiB8IENBTExfRElSX0FOU1dFUjsKICAgICAgICAgc3RhcnRfaW50ZXJuYWxfY29tbWFuZCAoSWQsIHBsY2ksIHNlbGVjdF9iX2NvbW1hbmQpOwotICAgICAgICByZXR1cm4gRkFMU0U7CisgICAgICAgIHJldHVybiBmYWxzZTsKICAgICAgIH0KICAgICB9CiAgIH0KICAgc2VuZGYoYXBwbCwgX1NFTEVDVF9CX1JFUXxDT05GSVJNLCBJZCwgTnVtYmVyLCAidyIsIEluZm8pOwotICByZXR1cm4gRkFMU0U7CisgIHJldHVybiBmYWxzZTsKIH0KIAogYnl0ZSBtYW51ZmFjdHVyZXJfcmVxKGR3b3JkIElkLCB3b3JkIE51bWJlciwgRElWQV9DQVBJX0FEQVBURVIgICAqIGEsIFBMQ0kgICAqIHBsY2ksIEFQUEwgICAqIGFwcGwsIEFQSV9QQVJTRSAqIHBhcm1zKQpAQCAtMzQ4OSw3ICszNDg5LDcgQEAKICAgICAgICAgICB9CiAKICAgICAgICAgICBwbGNpLT5TdGF0ZSA9IExPQ0FMX0NPTk5FQ1Q7Ci0gICAgICAgICAgcGxjaS0+bWFudWZhY3R1cmVyID0gVFJVRTsKKyAgICAgICAgICBwbGNpLT5tYW51ZmFjdHVyZXIgPSB0cnVlOwogICAgICAgICAgIHBsY2ktPmNvbW1hbmQgPSBfTUFOVUZBQ1RVUkVSX1I7CiAgICAgICAgICAgcGxjaS0+bV9jb21tYW5kID0gY29tbWFuZDsKICAgICAgICAgICBwbGNpLT5udW1iZXIgPSBOdW1iZXI7CkBAIC0zNTIwLDcgKzM1MjAsNyBAQAogICAgICAgICAgICAgICAgIHBsY2ktPmludGVybmFsX2NvbW1hbmQgPSBCTE9DS19QTENJOyAvKiByZWplY3Qgb3RoZXIgcmVxIG1lYW53aGlsZSAqLwogICAgICAgICAgICAgICAgIHBsY2ktPmNvbW1hbmQgPSAwOwogICAgICAgICAgICAgICAgIHNlbmRfcmVxKHBsY2kpOwotICAgICAgICAgICAgICAgIHJldHVybiBGQUxTRTsKKyAgICAgICAgICAgICAgICByZXR1cm4gZmFsc2U7CiAgICAgICAgICAgICAgIH0KICAgICAgICAgICAgICAgaWYoZGlyPT0xKSB7CiAgICAgICAgICAgICAgICAgc2lnX3JlcShwbGNpLENBTExfUkVRLDApOwpAQCAtMzU3Myw3ICszNTczLDcgQEAKICAgICAgIH0KICAgICAgIGVsc2UgaWYocmVxPT1MQVd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7CiAgICAgICBlbHNlCiAgICAgICB7CiAgICAgICAgIGlmIChyZXEgPT0gTl9YT04pCiAgICAgICAgIHsKICAgICAgICAgICBjaGFubmVsX3hfb24gKHBsY2ksIGNoKTsKICAgICAgICAgICBpZiAocGxjaS0+aW50ZXJuYWxfY29tbWFuZCkKLSAgICAgICAgICAgIGNvbnRyb2xfcmMgKHBsY2ksIHJlcSwgcmMsIGNoLCAwLCBUUlVFKTsKKyAgICAgICAgICAgIGNvbnRyb2xfcmMgKHBsY2ksIHJlcSwgcmMsIGNoLCAwLCB0cnVlKTsKICAgICAgICAgfQogICAgICAgICBlbHNlCiAgICAgICAgIHsKQEAgLTM5MzEsMjEgKzM5MzEsMjEgQEAKICAgICAgICAgICAgICAgfQogICAgICAgICAgICAgfQogICAgICAgICAgICAgY2hhbm5lbF94bWl0X3hvbiAocGxjaSk7Ci0gICAgICAgICAgICBjb250cm9sX3JjIChwbGNpLCAwLCByYywgY2gsIGdsb2JhbF9yZXEsIFRSVUUpOworICAgICAgICAgICAgY29udHJvbF9yYyAocGxjaSwgMCwgcmMsIGNoLCBnbG9iYWxfcmVxLCB0cnVlKTsKICAgICAgICAgICB9CiAgICAgICAgICAgZWxzZSBpZiAocGxjaS0+ZGF0YV9zZW50KQogICAgICAgICAgIHsKICAgICAgICAgICAgIGNoYW5uZWxfeG1pdF94b24gKHBsY2kpOwotICAgICAgICAgICAgcGxjaS0+ZGF0YV9zZW50ID0gRkFMU0U7CisgICAgICAgICAgICBwbGNpLT5kYXRhX3NlbnQgPSBmYWxzZTsKICAgICAgICAgICAgIHBsY2ktPk5MLlhOdW0gPSAxOwogICAgICAgICAgICAgZGF0YV9yYyAocGxjaSwgY2gpOwogICAgICAgICAgICAgaWYgKHBsY2ktPmludGVybmFsX2NvbW1hbmQpCi0gICAgICAgICAgICAgIGNvbnRyb2xfcmMgKHBsY2ksIHJlcSwgcmMsIGNoLCAwLCBUUlVFKTsKKyAgICAgICAgICAgICAgY29udHJvbF9yYyAocGxjaSwgcmVxLCByYywgY2gsIDAsIHRydWUpOwogICAgICAgICAgIH0KICAgICAgICAgICBlbHNlCiAgICAgICAgICAgewogICAgICAgICAgICAgY2hhbm5lbF94bWl0X3hvbiAocGxjaSk7Ci0gICAgICAgICAgICBjb250cm9sX3JjIChwbGNpLCByZXEsIHJjLCBjaCwgMCwgVFJVRSk7CisgICAgICAgICAgICBjb250cm9sX3JjIChwbGNpLCByZXEsIHJjLCBjaCwgMCwgdHJ1ZSk7CiAgICAgICAgICAgfQogICAgICAgICB9CiAgICAgICB9CkBAIC0zOTc0LDEyICszOTc0LDEyIEBACiAgICAgICAgIGlmIChyYyAhPSBBU1NJR05fT0spCiAgICAgICAgICAgZS0+SWQgPSAwOwogICAgICAgICBjaGFubmVsX3htaXRfeG9uIChwbGNpKTsKLSAgICAgICAgY29udHJvbF9yYyAocGxjaSwgMCwgcmMsIGNoLCBnbG9iYWxfcmVxLCBGQUxTRSk7CisgICAgICAgIGNvbnRyb2xfcmMgKHBsY2ksIDAsIHJjLCBjaCwgZ2xvYmFsX3JlcSwgZmFsc2UpOwogICAgICAgfQogICAgICAgZWxzZQogICAgICAgewogICAgICAgICBjaGFubmVsX3htaXRfeG9uIChwbGNpKTsKLSAgICAgICAgY29udHJvbF9yYyAocGxjaSwgcmVxLCByYywgY2gsIDAsIEZBTFNFKTsKKyAgICAgICAgY29udHJvbF9yYyAocGxjaSwgcmVxLCByYywgY2gsIDAsIGZhbHNlKTsKICAgICAgIH0KICAgICB9CiAgICAgLyoKQEAgLTQwNjUsOCArNDA2NSw4IEBACiAKICAgICBpZiAocGxjaS0+bGlfbm90aWZ5X3VwZGF0ZSkKICAgICB7Ci0gICAgICBwbGNpLT5saV9ub3RpZnlfdXBkYXRlID0gRkFMU0U7Ci0gICAgICBtaXhlcl9ub3RpZnlfdXBkYXRlIChwbGNpLCBGQUxTRSk7CisgICAgICBwbGNpLT5saV9ub3RpZnlfdXBkYXRlID0gZmFsc2U7CisgICAgICBtaXhlcl9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worICBieXRlIGZvcmNlX210X2luZm8gPSBmYWxzZTsKICAgYnl0ZSBkaXI7CiAgIGR3b3JkIGQ7CiAgIHdvcmQgdzsKQEAgLTQ5MzMsNyArNDkzMyw3IEBACiAgIHsKICAgICBpZihwbGNpLT5jcl9lbnF1aXJ5ICYmIHBsY2ktPmFwcGwpCiAgICAgewotICAgICAgcGxjaS0+Y3JfZW5xdWlyeSA9IEZBTFNFOworICAgICAgcGxjaS0+Y3JfZW5xdWlyeSA9IGZhbHNlOwogICAgICAgLyogZCA9IE1BTlVfSUQgICAgICAgICAgICAqLwogICAgICAgLyogdyA9IG1fY29tbWFuZCAgICAgICAgICAqLwogICAgICAgLyogYiA9IHRvdGFsIGxlbmd0aCAgICAgICAqLwpAQCAtNTE1OCw3ICs1MTU4LDcgQEAKICAgICAgICAgaWYoYXBwbGljYXRpb25baV0uQ0RFbmFibGUpCiAgICAgICAgIHsKICAgICAgICAgICBpZihhcHBsaWNhdGlvbltpXS5JZCkgc2VuZGYoJmFwcGxpY2F0aW9uW2ldLF9GQUNJTElUWV9JLElkLDAsIndzIiwzLCBTU19JbmQpOwotICAgICAgICAgIGFwcGxpY2F0aW9uW2ldLkNERW5hYmxlID0gRkFMU0U7CisgICAgICAgICAgYXBwbGljYXRpb25baV0uQ0RFbmFibGUgPSBmYWxzZTsKICAgICAgICAgfQogICAgICAgfQogICAgICAgYnJlYWs7CkBAIC01Mzc1LDcgKzUzNzUsNyBAQAogICAgICAgICBpZihhcHBsaWNhdGlvbltpXS5DREVuYWJsZSkKICAgICAgICAgewogICAgICAgICAgIGlmKGFwcGxpY2F0aW9uW2ldLklkKSBzZW5kZigmYXBwbGljYXRpb25baV0sX0ZBQ0lMSVRZX0ksSWQsMCwid3MiLDMsIFNTX0luZCk7Ci0gICAgICAgICAgYXBwbGljYXRpb25baV0uQ0RFbmFibGUgPSBGQUxTRTsKKyAgICAgICAgICBhcHBsaWNhdGlvbltpXS5DREVuYWJsZSA9IGZhbHNlOwogICAgICAgICB9CiAgICAgICB9CiAgICAgICBicmVhazsKQEAgLTU3MzAsNyArNTczMCw3IEBACiAgICAgICAgICAgICAgICAgICAgICAgICBwbGNpLAogICAgICAgICAgICAgICAgICAgICAgICAgSWQsCiAgICAgICAgICAgICAgICAgICAgICAgICBwYXJtcywKLSAgICAgICAgICAgICAgICAgICAgICAgIFNlbmRNdWx0aUlFKHBsY2ksSWQsbXVsdGlfcGlfcGFybXMsIFBJLCAweDIxMCwgVFJVRSkpOworICAgICAgICAgICAgICAgICAgICAgICAgU2VuZE11bHRpSUUocGxjaSxJZCxtdWx0aV9waV9wYXJtcywgUEksIDB4MjEwLCB0cnVlKSk7CiAgICAgICAgIH0KICAgICAgIH0KICAgICAgIGNsZWFyX2NfaW5kX21hc2tfYml0IChwbGNpLCBNQVhfQVBQTCk7CkBAIC02MTE3LDM4ICs2MTE3LDM4IEBACiAgICAgICAgIGRidWcoMSxkcHJpbnRmKCJDUE4gIikpOwogICAgICAgICBJbmZvX051bWJlciA9IDB4MDA3MDsKICAgICAgICAgSW5mb19NYXNrICAgPSAweDgwOwotICAgICAgICBJbmZvX1NlbnRfRmxhZyA9IFRSVUU7CisgICAgICAgIEluZm9fU2VudF9GbGFnID0gdHJ1ZTsKICAgICAgICAgYnJlYWs7CiAgICAgICBjYXNlIDg6ICAvKiBkaXNwbGF5ICAgICAgKi8KICAgICAgICAgZGJ1ZygxLGRwcmludGYoImRpc3BsYXkoJWQpIixpKSk7CiAgICAgICAgIEluZm9fTnVtYmVyID0gMHgwMDI4OwogICAgICAgICBJbmZvX01hc2sgPSAweDA0OwotICAgICAgICBJbmZvX1NlbnRfRmxhZyA9IFRSVUU7CisgICAgICAgIEluZm9fU2VudF9GbGFnID0gdHJ1ZTsKICAgICAgICAgYnJlYWs7CiAgICAgICBjYXNlIDE2OiAvKiBDaGFubmVsIElkICovCiAgICAgICAgIGRidWcoMSxkcHJpbnRmKCJDSEkiKSk7CiAgICAgICAgIEluZm9fTnVtYmVyID0gMHgwMDE4OwogICAgICAgICBJbmZvX01hc2sgPSAweDEwMDsKLSAgICAgICAgSW5mb19TZW50X0ZsYWcgPSBUUlVFOworICAgICAgICBJbmZvX1NlbnRfRmxhZyA9IHRydWU7CiAgICAgICAgIG1peGVyX3NldF9iY2hhbm5lbF9pZCAocGxjaSwgSW5mb19FbGVtZW50KTsKICAgICAgICAgYnJlYWs7CiAgICAgICBjYXNlIDE5OiAvKiBSZWRpcmVjdGVkIE51bWJlciAqLwogICAgICAgICBkYnVnKDEsZHByaW50ZigiUkROIikpOwogICAgICAgICBJbmZvX051bWJlciA9IDB4MDA3NDsKICAgICAgICAgSW5mb19NYXNrID0gMHg0MDA7Ci0gICAgICAgIEluZm9fU2VudF9GbGFnID0gVFJVRTsKKyAgICAgICAgSW5mb19TZW50X0ZsYWcgPSB0cnVlOwogICAgICAgICBicmVhazsKICAgICAgIGNhc2UgMjA6IC8qIFJlZGlyZWN0ZWQgTnVtYmVyIGV4dGVuZGVkICovCiAgICAgICAgIGRidWcoMSxkcHJpbnRmKCJSRFgiKSk7CiAgICAgICAgIEluZm9fTnVtYmVyID0gMHgwMDczOwogICAgICAgICBJbmZvX01hc2sgPSAweDQwMDsKLSAgICAgICAgSW5mb19TZW50X0ZsYWcgPSBUUlVFOworICAgICAgICBJbmZvX1NlbnRfRmxhZyA9IHRydWU7CiAgICAgICAgIGJyZWFrOwogICAgICAgY2FzZSAyMjogLyogUmVkaXJlY2luZyBOdW1iZXIgICovCiAgICAgICAgIGRidWcoMSxkcHJpbnRmKCJSSU4iKSk7CiAgICAgICAgIEluZm9fTnVtYmVyID0gMHgwMDc2OwogICAgICAgICBJbmZvX01hc2sgPSAweDQwMDsKLSAgICAgICAgSW5mb19TZW50X0ZsYWcgPSBUUlVFOworICAgICAgICBJbmZvX1NlbnRfRmxhZyA9IHRydWU7CiAgICAgICAgIGJyZWFrOwogICAgICAgZGVmYXVsdDoKICAgICAgICAgSW5mb19OdW1iZXIgPSAwOwpAQCAtNjMxMiw3ICs2MzEyLDcgQEAKICAgICAgICAgJiYgcGxjaS0+YWRhcHRlci0+SW5mb19NYXNrW2FwcGwtPklkLTFdICZJbmZvX01hc2spCiAgICAgICAgIHsKICAgICAgICAgICBkYnVnKDEsZHByaW50ZigiTkNSX0luZCIpKTsKLSAgICAgICAgICBpZXNlbnQ9VFJVRTsKKyAgICAgICAgICBpZXNlbnQ9dHJ1ZTsKICAgICAgICAgICBzZW5kZigmYXBwbGljYXRpb25bal0sX0lORk9fSSxJZCYweDBmLDAsIndTIixJbmZvX051bWJlcixJbmZvX0VsZW1lbnQpOwogICAgICAgICB9CiAgICAgICB9CkBAIC02MzMwLDcgKzYzMzAsNyBAQAogICAgICAgICAgIGlmKHRlc3RfY19pbmRfbWFza19iaXQgKHBsY2ksIGopKQogICAgICAgICAgIHsKICAgICAgICAgICAgIGRidWcoMSxkcHJpbnRmKCJPdmxfSW5kIikpOwotICAgICAgICAgICAgaWVzZW50PVRSVUU7CisgICAgICAgICAgICBpZXNlbnQ9dHJ1ZTsKICAgICAgICAgICAgIHNlbmRmKCZhcHBsaWNhdGlvbltqXSxfSU5GT19JLElkLDAsIndTIixJbmZvX051bWJlcixJbmZvX0VsZW1lbnQpOwogICAgICAgICAgIH0KICAgICAgICAgfQpAQCAtNjM0MCw3ICs2MzQwLDcgQEAKICAgICAmJiBwbGNpLT5hZGFwdGVyLT5JbmZvX01hc2tbcGxjaS0+YXBwbC0+SWQtMV0gJkluZm9fTWFzaykKICAgICB7CiAgICAgICBkYnVnKDEsZHByaW50ZigiU3RkX0luZCIpKTsKLSAgICAgIGllc2VudD1UUlVFOworICAgICAgaWVzZW50PXRydWU7CiAgICAgICBzZW5kZihwbGNpLT5hcHBsLF9JTkZPX0ksSWQsMCwid1MiLEluZm9fTnVtYmVyLEluZm9fRWxlbWVudCk7CiAgICAgfQogICB9CkBAIC02MzkxLDcgKzYzOTEsNyBAQAogICAgICAgICAmJiBhcHBsLT5JZAogICAgICAgICAmJiBwbGNpLT5hZGFwdGVyLT5JbmZvX01hc2tbYXBwbC0+SWQtMV0gJkluZm9fTWFzaykKICAgICAgICAgewotICAgICAgICAgIGllc2VudCA9IFRSVUU7CisgICAgICAgICAgaWVzZW50ID0gdHJ1ZTsKICAgICAgICAgICBkYnVnKDEsZHByaW50ZigiTWx0X05DUl9JbmQiKSk7CiAgICAgICAgICAgc2VuZGYoJmFwcGxpY2F0aW9uW2pdLF9JTkZPX0ksSWQmMHgwZiwwLCJ3UyIsSW5mb19OdW1iZXIsSW5mb19FbGVtZW50KTsKICAgICAgICAgfQpAQCAtNjQwMyw3ICs2NDAzLDcgQEAKICAgICAgIHsKICAgICAgICAgaWYodGVzdF9jX2luZF9tYXNrX2JpdCAocGxjaSwgaikpCiAgICAgICAgIHsKLSAgICAgICAgICBpZXNlbnQgPSBUUlVFOworICAgICAgICAgIGllc2VudCA9IHRydWU7CiAgICAgICAgICAgZGJ1ZygxLGRwcmludGYoIk1sdF9PdmxfSW5kIikpOwogICAgICAgICAgIHNlbmRmKCZhcHBsaWNhdGlvbltqXSxfSU5GT19JLElkLDAsIndTIixJbmZvX051bWJlcixJbmZvX0VsZW1lbnQpOwogICAgICAgICB9CkBAIC02NDEyLDcgKzY0MTIsNyBAQAogICAgIGVsc2UgaWYoSW5mb19OdW1iZXIKICAgICAmJiBwbGNpLT5hZGFwdGVyLT5JbmZvX01hc2tbcGxjaS0+YXBwbC0+SWQtMV0gJkluZm9fTWFzaykKICAgICB7Ci0gICAgICBpZXNlbnQgPSBUUlVFOworICAgICAgaWVzZW50ID0gdHJ1ZTsKICAgICAgIGRidWcoMSxkcHJpbnRmKCJNbHRfU3RkX0luZCIpKTsKICAgICAgIHNlbmRmKHBsY2ktPmFwcGwsX0lORk9fSSxJZCwwLCJ3UyIsSW5mb19OdW1iZXIsSW5mb19FbGVtZW50KTsKICAgICB9CkBAIC02ODEyLDcgKzY4MTIsNyBAQAogICAgICAgICB9CiAgICAgICAgIGlmICgoKHBsY2ktPk5MLkluZCAmIDB4MGY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N0X3dyaXRlX3Byb2cpKQogICAgICAgICB7CiAgICAgICAgICAgZG8KICAgICAgICAgICB7CkBAIC0xMTA1MCw3ICsxMTA0OSw3IEBACiAgICAgewogICAgICAgcGxjaS0+aW50ZXJuYWxfY29tbWFuZCA9IHBsY2ktPmxpX3dyaXRlX2NvbW1hbmQ7CiAgICAgICBpZiAocGxjaV9ubF9idXN5IChwbGNpKSkKLSAgICAgICAgcmV0dXJuIChUUlVFKTsKKyAgICAgICAgcmV0dXJuICh0cnVlKTsKICAgICAgIGlmIChhLT5saV9wcmkpCiAgICAgICB7CiAgICAgICAgICoocCsrKSA9IFVEQVRBX1JFUVVFU1RfU0VUX01JWEVSX0NPRUZTX1BSSV9TWU5DOwpAQCAtMTEwOTAsNyArMTEwODksNyBAQAogICAgICAgICAgICAgY2hfbWFwW2orMV0gPSAoYnl0ZSkoaisxKTsKICAgICAgICAgICB9CiAgICAgICAgIH0KLSAgICAgICAgZm9yIChuID0gMDsgbiA8IHNpemVvZihtaXhlcl93cml0ZV9wcm9nX2JyaSkgLyBzaXplb2YobWl4ZXJfd3JpdGVfcHJvZ19icmlbMF0pOyBuKyspCisgICAgICAgIGZvciAobiA9IDA7IG4gPCBBUlJBWV9TSVpFKG1peGVyX3dyaXRlX3Byb2dfYnJpKTsgbisrKQogICAgICAgICB7CiAgICAgICAgICAgaSA9IGEtPmxpX2Jhc2UgKyBjaF9tYXBbbWl4ZXJfd3JpdGVfcHJvZ19icmlbbl0udG9fY2hdOwogICAgICAgICAgIGogPSBhLT5saV9iYXNlICsgY2hfbWFwW21peGVyX3dyaXRlX3Byb2dfYnJpW25dLmZyb21fY2hdOwpAQCAtMTExMjcsNyArMTExMjYsNyBAQAogICAgIHsKICAgICAgIHBsY2ktPmludGVybmFsX2NvbW1hbmQgPSBwbGNpLT5saV93cml0ZV9jb21tYW5kOwogICAgICAgaWYgKHBsY2lfbmxfYnVzeSAocGxjaSkpCi0gICAgICAgIHJldHVybiAoVFJVRSk7CisgICAgICA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NJRU5UUzsKICAgICAgICAgICAgIHN0YXJ0X2ludGVybmFsX2NvbW1hbmQgKElkLCBwbGNpLCBlY19jb21tYW5kKTsKLSAgICAgICAgICAgIHJldHVybiAoRkFMU0UpOworICAgICAgICAgICAgcmV0dXJuIChmYWxzZSk7CiAKICAgICAgICAgICBjYXNlIEVDX1JFU1VNRV9DT0VGRklDSUVOVF9VUERBVEU6CiAgICAgICAgICAgICBwbGNpLT5lY19pZGlfb3B0aW9ucyAmPSB+TEVDX0ZSRUVaRV9DT0VGRklDSUVOVFM7CiAgICAgICAgICAgICBzdGFydF9pbnRlcm5hbF9jb21tYW5kIChJZCwgcGxjaSwgZWNfY29tbWFuZCk7Ci0gICAgICAgICAgICByZXR1cm4gKEZBTFNFKTsKKyAgICAgICAgICAgIHJldHVybiAoZmFsc2UpOwogCiAgICAgICAgICAgY2FzZSBFQ19SRVNFVF9DT0VGRklDSUVOVFM6CiAgICAgICAgICAgICBwbGNpLT5lY19pZGlfb3B0aW9ucyB8PSBMRUNfUkVTRVRfQ09FRkZJQ0lFTlRTOwogICAgICAgICAgICAgc3RhcnRfaW50ZXJuYWxfY29tbWFuZCAoSWQsIHBsY2ksIGVjX2NvbW1hbmQpOwotICAgICAgICAgICAgcmV0dXJuIChGQUxTRSk7CisgICAgICAgICAgICByZXR1cm4gKGZhbHNlKTsKIAogICAgICAgICAgIGRlZmF1bHQ6CiAgICAgICAgICAgICBkYnVnICgxLCBkcHJpbnRmICgiWyUwNmx4XSAlcywlZDogRUMgdW5rbm93biByZXF1ZXN0ICUwNHgiLApAQCAtMTI5NzgsMTQgKzEyOTc3LDE0IEBACiAgICAgICAgICAgY2FzZSBFQ19FTkFCTEVfT1BFUkFUSU9OOgogICAgICAgICAgICAgcGxjaS0+ZWNfaWRpX29wdGlvbnMgJj0gfkxFQ19GUkVFWkVfQ09FRkZJQ0lFTlRTOwogICAgICAgICAgICAgc3RhcnRfaW50ZXJuYWxfY29tbWFuZCAoSWQsIHBsY2ksIGVjX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rKykKKyAgICAgIGZvcihrPTAsYnVzeT1mYWxzZTsgazxhLT5tYXhfcGxjaTsgaysrKQogICAgICAgewogICAgICAgICBpZihhLT5wbGNpW2tdLklkKSAKICAgICAgICAgewogICAgICAgICAgIGF1eHBsY2kgPSAmYS0+cGxjaVtrXTsKICAgICAgICAgICBpZihhdXhwbGNpLT5hcHBsID09ICZhcHBsaWNhdGlvbltpXSkgLyogYXBwbGljYXRpb24gaGFzIGEgYnVzeSBQTENJICovCiAgICAgICAgICAgewotICAgICAgICAgICAgYnVzeSA9IFRSVUU7CisgICAgICAgICAgICBidXN5ID0gdHJ1ZTsKICAgICAgICAgICAgIGRidWcoMSxkcHJpbnRmKCJBcHBsIDB4JXggaXMgYnVzeSIsaSsxKSk7CiAgICAgICAgICAgfQogICAgICAgICAgIGVsc2UgaWYodGVzdF9jX2luZF9tYXNrX2JpdCAoYXV4cGxjaSwgaSkpIC8qIGFwcGxpY2F0aW9uIGhhcyBhbiBpbmNvbWluZyBjYWxsIHBlbmRpbmcgKi8KICAgICAgICAgICB7Ci0gICAgICAgICAgICBidXN5ID0gVFJVRTsKKyAgICAgICAgICAgIGJ1c3kgPSB0cnVlOwogICAgICAgICAgICAgZGJ1ZygxLGRwcmludGYoIkFwcGwgMHgleCBoYXMgaW5jLiBjYWxsIHBlbmRpbmciLGkrMSkpOwogICAgICAgICAgIH0KICAgICAgICAgfQpAQCAtMTQ3OTEsMTMgKzE0NzkwLDEzIEBACiAgICAgICAgIGlmKGo9PU1BWF9DSVBfVFlQRVMpICAgICAgIC8qIGFsbCBncm91cHMgYXJlIGluIHVzZSBidXQgZ3JvdXAgc3RpbGwgbm90IGZvdW5kICovCiAgICAgICAgIHsgICAgICAgICAgICAgICAgICAgICAgICAgICAvKiB0aGUgTUFYX0NJUF9UWVBFUyBncm91cCBlbmFibGVzIGFsbCBjYWxscyBiZWNhdXNlIG9mIGZpZWxkIG92ZXJmbG93ICovCiAgICAgICAgICAgYXBwbF9udW1iZXJfZ3Jv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IDwgODAyMDAwMDAwKSByZWcwNSA9IDB4NTQ7IC8qIDgwMiBNSHogKi8KKwllbHNlICAgICAgICAgICAgICAgICAgICAgICByZWcwNSA9IDB4NzQ7CisKKwkvKiAweDUgKi8KKwlyZFsyXS52YWwgPSByZWcwNTsKKworCS8qIDA3IC0gc2V0IGZyZXF1ZW5jeTogMzIgTUh6IHNjYWxlICovCisJcmRbNF0udmFsID0gKGZyZXEgKyBRVDEwMTBfT0ZGU0VUKSAvIEZSRVExOworCisJLyogMDkgLSBjaGFuZ2VzIGV2ZXJ5IDgvMjQgTUh6ICovCisJaWYgKG1vZDEgPCA4MDAwMDAwKSByZFs2XS52YWwgPSAweDFkOworCWVsc2UgICAgICAgICAgICAgICAgcmRbNl0udmFsID0gMHgxYzsKKworCS8qIDBhIC0gc2V0IGZyZXF1ZW5jeTogNCBNSHogc2NhbGUgKG1heCAyOCBNSHopICovCisJaWYgICAgICAobW9kMSA8IDEqRlJFUTIpIHJkWzddLnZhbCA9IDB4MDk7IC8qICArMCBNSHogKi8KKwllbHNlIGlmIChtb2QxIDwgMipGUkVRMikgcmRbN10udmFsID0gMHgwODsgLyogICs0IE1IeiAqLworCWVsc2UgaWYgKG1vZDEgPCAzKkZSRVEyKSByZFs3XS52YWwgPSAweDBmOyAvKiAgKzggTUh6ICovCisJZWxzZSBpZiAobW9kMSA8IDQqRlJFUTIpIHJkWzddLnZhbCA9IDB4MGU7IC8qICsxMiBNSHogKi8KKwllbHNlIGlmIChtb2QxIDwgNSpGUkVRMikgcmRbN10udmFsID0gMHgwZDsgLyogKzE2IE1IeiAqLworCWVsc2UgaWYgKG1vZDEgPCA2KkZSRVEyKSByZFs3XS52YWwgPSAweDBjOyAvKiArMjAgTUh6ICovCisJZWxzZSBpZiAobW9kMSA8IDcqRlJFUTIpIHJkWzddLnZhbCA9IDB4MGI7IC8qICsyNCBNSHogKi8KKwllbHNlICAgICAgICAgICAgICAgICAgICAgcmRbN10udmFsID0gMHgwYTsgLyogKzI4I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ICBmdW5jdGlvbiBtYXkgYWRqdXN0IHRoZSB3aWR0aCBhbmQvb3IgaGVpZ2h0IGluc3RlYWQsIHJvdW5kaW5nIHdpZHRoCisgICB0byAod2lkdGggKyB3aWR0aF9iaWFzKSAmIHdpZHRoX21hc2suIElmIGFkanVzdF9jcm9wIGlzIFRSVUUgaXQgbWF5CisgICBhbHNvIGFkanVzdCB0aGUgY3VycmVudCBjcm9wcGluZyBwYXJhbWV0ZXJzIHRvIGdldCBjbG9zZXIgdG8gdGhlCisgICBkZXNpcmVkIGltYWdlIHNpemUuICovCitzdGF0aWMgaW50CitsaW1pdF9zY2FsZWRfc2l6ZSAgICAgICAoc3RydWN0IGJ0dHZfZmggKiAgICAgICAgICAgICAgIGZoLAorCQkJIF9fczMyICogICAgICAgICAgICAgICAgICAgICAgICB3aWR0aCwKKwkJCSBfX3MzMiAqICAgICAgICAgICAgICAgICAgICAgICAgaGVpZ2h0LAorCQkJIGVudW0gdjRsMl9maWVsZCAgICAgICAgICAgICAgICBmaWVsZCwKKwkJCSB1bnNpZ25lZCBpbnQJCQl3aWR0aF9tYXNrLAorCQkJIHVuc2lnbmVkIGludAkJCXdpZHRoX2JpYXMsCisJCQkgaW50ICAgICAgICAgICAgICAgICAgICAgICAgICAgIGFkanVzdF9zaXplLAorCQkJIGludCAgICAgICAgICAgICAgICAgICAgICAgICAgICBhZGp1c3RfY3JvcCkKK3sKKwlzdHJ1Y3QgYnR0diAqYnR2ID0gZmgtPmJ0djsKKwljb25zdCBzdHJ1Y3QgdjRsMl9yZWN0ICpiOworCXN0cnVjdCBidHR2X2Nyb3AgKmM7CisJX19zMzIgbWluX3dpZHRoOworCV9fczMyIG1pbl9oZWlnaHQ7CisJX19zMzIgbWF4X3dpZHRoOworCV9fczMyIG1heF9oZWlnaHQ7CisJaW50IHJjOworCisJQlVHX09OKChpbnQpIHdpZHRoX21hc2sgPj0gMCB8fAorCSAgICAgICB3aWR0aF9iaWFzID49ICh1bnNpZ25lZCBpbnQpI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HNpbmdsZSBmaWVsZHMuIFNlZSBhbHNvIGJ0dHZfY3JvcF9yZXNldCgpIGFuZAorCSAgIGJ0dHZfY3JvcF9hZGp1c3QoKSBpbiBidHR2LWRyaXZlci5jLiAqLworCV9fczMyICAgICAgICAgICAgICAgICAgbWluX3NjYWxlZF93aWR0aDsKKwlfX3MzMiAgICAgICAgICAgICAgICAgIG1pbl9zY2FsZWRfaGVpZ2h0OworCV9fczMyICAgICAgICAgICAgICAgICAgbWF4X3NjYWxlZF93aWR0aDsKKwlfX3MzMiAgICAgICAgICAgICAgICAgIG1heF9zY2FsZWRfaGVpZ2h0OworfTsKKwogc3RydWN0IGJ0dHZfZmggewogCXN0cnVjdCBidHR2ICAgICAgICAgICAgICAqYnR2OwogCWludCByZXNvdXJjZXM7CkBAIC0xNjAsMTMgKzIwNCwxOSBAQAogCWludCAgICAgICAgICAgICAgICAgICAgICB3aWR0aDsKIAlpbnQgICAgICAgICAgICAgICAgICAgICAgaGVpZ2h0OwogCi0JLyogY3VycmVudCBzZXR0aW5ncyAqLworCS8qIHZpZGVvIG92ZXJsYXkgKi8KIAljb25zdCBzdHJ1Y3QgYnR0dl9mb3JtYXQgKm92Zm10OwogCXN0cnVjdCBidHR2X292ZXJsYXkgICAgICBvdjsKIAotCS8qIHZpZGVvIG92ZXJsYXkgKi8KKwkvKiBBcHBsaWNhdGlvbiBjYWxsZWQgVklESU9DX1NfQ1JPUC4gKi8KKwlpbnQgICAgICAgICAgICAgICAgICAgICAgZG9fY3JvcDsKKworCS8qIHZiaSBjYXB0dXJlICovCiAJc3RydWN0IHZpZGVvYnVmX3F1ZXVlICAgIHZiaTsKLQlpbnQgICAgICAgICAgICAgICAgICAgICAgbGluZXM7CisJLyogQ3VycmVudCBWQkkgY2FwdHVyZSB3aW5kb3cgYXMgc2VlbiB0aHJvdWdoIHRoaXMgZmggKGNhbm5vdAorCSAgIGJlIGdsb2JhbCBmb3IgY29tcGF0aWJpbGl0eSB3aXRoIGVhcmxpZXIg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LCBmZV9zZWNfdm9sdGFnZV90IHZvbHRhZ2UpOworI2VuZGlmCiAKIAkvKiBzdGF0ZSBpbmZvICovCiAJc3RydWN0IHRhc2tfc3RydWN0ICAgICAgICAgKmt0aHJlYWQ7Ci0Jc3RydWN0IGN4ODhfdHZub3JtICAgICAgICAgKnR2bm9ybTsKKwl2NGwyX3N0ZF9pZCAgICAgICAgICAgICAgICB0dm5vcm07CiAJdTMyICAgICAgICAgICAgICAgICAgICAgICAgdHZhdWRpbzsKIAl1MzIgICAgICAgICAgICAgICAgICAgICAgICBhdWRpb21vZGVfbWFudWFsOwogCXUzMiAgICAgICAgICAgICAgICAgICAgICAgIGF1ZGlvbW9kZV9jdXJyZW50OwpAQCAtNDYwLDEyICs0NjQsMTQgQEAKIAlpbnQgICAgICAgICAgICAgICAgICAgICAgICB3aWR0aDsKIAlpbnQgICAgICAgICAgICAgICAgICAgICAgICBoZWlnaHQ7CiAKKyNpZiBkZWZpbmVkKENPTkZJR19WSURFT19CVUZfRFZCKSB8fCBkZWZpbmVkKENPTkZJR19WSURFT19CVUZfRFZCX01PRFVMRSkKIAkvKiBmb3IgZHZiIG9ubHkgKi8KIAlzdHJ1Y3QgdmlkZW9idWZfZHZiICAgICAgICBkdmI7CiAJdm9pZCogICAgICAgICAgICAgICAgICAgICAgZmVfaGFuZGxlOwogCWludCAgICAgICAgICAgICAgICAgICAgICAgICgqZmVfcmVsZWFzZSkodm9pZCAqaGFuZGxlKTsKIAogCXZvaWQJCQkgICAqY2FyZF9wcml2OworI2VuZGlmCiAJLyogZm9yIHN3aXRjaGluZyBtb2R1bGF0aW9uIHR5cGVzICovCiAJdW5zaWduZWQgY2hhciAgICAgICAgICAgICAgdHNfZ2VuX2NudHJsOwogCkBAIC01MzYsNyArNTQyLDcgQEAKIAogZXh0ZXJuIGludCBjeDg4X3NldF9zY2FsZShzdHJ1Y3QgY3g4OF9jb3JlICpjb3JlLCB1bnNpZ25lZCBpbnQgd2lkdGgsCiAJCQkgIHVu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qKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKgogICogVjRMMiBkcml2ZXIgZm9yIEVUNjFYWzEyXTUxIFBDIENhbWVyYSBDb250cm9sbGVycyAgICAgICAgICAgICAgICAgICAgICAgKgogICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgotICogQ29weXJpZ2h0IChDKSAyMDA2IGJ5IEx1Y2EgUmlzb2xpYSA8bHVjYS5yaXNvbGlhQHN0dWRpby51bmliby5pdD4gICAgICAgKgorICogQ29weXJpZ2h0IChDKSAyMDA2LTIwMDcgYnkgTHVjYSBSaXNvbGlhIDxsdWNhLnJpc29saWFAc3R1ZGlvLnVuaWJvLml0PiAgKgogICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgogICogVGhpcyBwcm9ncmFtIGlzIGZyZWUgc29mdHdhcmU7IHlvdSBjYW4gcmVkaXN0cmlidXRlIGl0IGFuZC9vciBtb2RpZnkgICAgKgogICogaXQgdW5kZXIgdGhlIHRlcm1zIG9mIHRoZSBHTlUgR2VuZXJhbCBQdWJsaWMgTGljZW5zZSBhcyBwdWJsaXNoZWQgYnkgICAgKgpAQCAtNDgsOCArNDgsOCBAQAogI2RlZmluZSBFVDYxWDI1MV9NT0RVTEVfQVVUSE9SICAiKEMpIDIwMDYgTHVjYSBSaXNvbGlhIgogI2RlZmluZSBFVDYxWDI1MV9BVVRIT1JfRU1BSUwgICAiPGx1Y2Eucmlzb2xpYUBzdHVkaW8udW5pYm8uaXQ+IgogI2RlZmluZSBFVDYxWDI1MV9NT0RVTEVfTElDRU5TRSAiR1BMIgotI2RlZmluZSBFVDYxWDI1MV9NT0RVTEVfVkVSU0lPTiAiMToxLjAyIgotI2RlZmluZSBFVDYxWDI1MV9NT0RVTEVfVkVSU0lPTl9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VlKGNhbS0+Y29udHJvbF9idWZmZXIpOwpkaWZmIC0tZ2l0IGEvZHJpdmVycy9tZWRpYS92aWRlby9ldDYxeDI1MS9ldDYxeDI1MV9zZW5zb3IuaCBiL2RyaXZlcnMvbWVkaWEvdmlkZW8vZXQ2MXgyNTEvZXQ2MXgyNTFfc2Vuc29yLmgKaW5kZXggNjVlZGQwOC4uNWZhZGI1ZCAxMDA2NDQKLS0tIGEvZHJpdmVycy9tZWRpYS92aWRlby9ldDYxeDI1MS9ldDYxeDI1MV9zZW5zb3IuaAorKysgYi9kcml2ZXJzL21lZGlhL3ZpZGVvL2V0NjF4MjUxL2V0NjF4MjUxX3NlbnNvci5oCkBAIC0xLDcgKzEsNyBAQAogLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKgogICogQVBJIGZvciBpbWFnZSBzZW5zb3JzIGNvbm5lY3RlZCB0byBFVDYxWFsxMl01MSBQQyBDYW1lcmEgQ29udHJvbGxlcnMgICAgKgogICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgotICogQ29weXJpZ2h0IChDKSAyMDA2IGJ5IEx1Y2EgUmlzb2xpYSA8bHVjYS5yaXNvbGlhQHN0dWRpby51bmliby5pdD4gICAgICAgKgorICogQ29weXJpZ2h0IChDKSAyMDA2LTIwMDcgYnkgTHVjYSBSaXNvbGlhIDxsdWNhLnJpc29saWFAc3R1ZGlvLnVuaWJvLml0PiAgKgogICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgogICogVGhpcyBwcm9ncmFtIGlzIGZyZWUgc29mdHdhcmU7IHlvdSBjYW4gcmVkaXN0cmlidXRlIGl0IGFuZC9vciBtb2RpZnkgICAgKgogICogaXQgdW5kZXIgdGhlIHRlcm1zIG9mI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QorKysgYi9kcml2ZXJzL21lZGlhL3ZpZGVvL3NuOWMxMDIvTWFrZWZpbGUKQEAgLTEsNSArMSw1IEBACiBzbjljMTAyLW9ianMgICAgOj0gc245YzEwMl9jb3JlLm8gc245YzEwMl9odjcxMzFkLm8gc245YzEwMl9taTAzNDMubyBcCi0JCSAgIHNuOWMxMDJfb3Y3NjMwLm8gc245YzEwMl9wYXMxMDZiLm8gc245YzEwMl9wYXMyMDJiY2EubyBcCisJCSAgIHNuOWMxMDJfb3Y3NjMwLm8gc245YzEwMl9vdjc2NjAubyBzbjljMTAyX3BhczEwNmIubyBcCiAJCSAgIHNuOWMxMDJfcGFzMjAyYmNiLm8gc245YzEwMl90YXM1MTEwYzFiLm8gXAogCQkgICBzbjljMTAyX3RhczUxMzBkMWIubwogCmRpZmYgLS1naXQgYS9kcml2ZXJzL21lZGlhL3ZpZGVvL3NuOWMxMDIvc245YzEwMi5oIGIvZHJpdmVycy9tZWRpYS92aWRlby9zbjljMTAyL3NuOWMxMDIuaAppbmRleCAyYzZmZjM5Li41NDI4ZjM0IDEwMDY0NAotLS0gYS9kcml2ZXJzL21lZGlhL3ZpZGVvL3NuOWMxMDIvc245YzEwMi5oCisrKyBiL2RyaXZlcnMvbWVkaWEvdmlkZW8vc245YzEwMi9zbjljMTAyLmgKQEAgLTEsNSArMSw1IEBACiAvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqCi0gKiBWNEwyIGRyaXZlciBmb3IgU045QzEweCBQQyBDYW1lcmEgQ29udHJvbGxlcnMgICAgICAgICAgICAgICAgICAgICAgICAgICAqCisgKiBWNEwyIGRyaXZlciBmb3IgU045QzF4eCBQQyBDYW1lcmEgQ29udHJvbGxlcnMgICAgICAgICAgICAgICAgICAgICAgICAgICAqCiAgKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIC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9kcml2ZXJzL21lZGlhL3ZpZGVvL3NuOWMxMDIvc245YzEwMl9jb25maWcuaApuZXcgZmlsZSBtb2RlIDEwMDY0NAppbmRleCAwMDAwMDAwLi4wZjRlMDM3Ci0tLSAvZGV2L251bGwKKysrIGIvZHJpdmVycy9tZWRpYS92aWRlby9zbjljMTAyL3NuOWMxMDJfY29uZmlnLmgKQEAgLTAsMCArMSw4NiBAQAorLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKgorICogR2xvYmFsIHBhcmFtZXRlcnMgZm9yIHRoZSBWNEwyIGRyaXZlciBmb3IgU045QzF4eCBQQyBDYW1lcmEgQ29udHJvbGxlcnMgKgorICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgorICogQ29weXJpZ2h0IChDKSAyMDA3IGJ5IEx1Y2EgUmlzb2xpYSA8bHVjYS5yaXNvbGlhQHN0dWRpby51bmliby5pdD4gICAgICAgKgorICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgorICogVGhpcyBwcm9ncmFtIGlzIGZyZWUgc29mdHdhcmU7IHlvdSBjYW4gcmVkaXN0cmlidXRlIGl0IGFuZC9vciBtb2RpZnkgICAgKgorICogaXQgdW5kZXIgdGhlIHRlcm1zIG9mIHRoZSBHTlUgR2VuZXJhbCBQdWJsaWMgTGljZW5zZSBhcyBwdWJsaXNoZWQgYnkgICAgKgorICogdGhlIEZyZWUgU29mdHdhcmUgRm91bmRhdGlvbjsgZWl0aGVyIHZlcnNpb24gMiBvZiB0aGUgTGljZW5zZSwgb3IgICAgICAgKgorICogKGF0IHlvdXIgb3B0aW9uKSBhbnkgbGF0ZXIgdmVyc2lvbi4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgorICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgorICogVGhpcyBwcm9ncmFtIGlzIGRpc3RyaWJ1dGVkIGluIHRoZSBob3BlIHRoYXQgaXQgd2lsbCBiZSB1c2VmdWwsICAgICAgICAgKgorICogYnV0IFdJVEhPVVQgQU5ZIFdBUlJBTlRZOyB3aXRob3V0IGV2ZW4gdGhlIGltcGxpZWQgd2FycmFudHkgb2YgICAgICAgICAgKgorICogTUVSQ0hBTlRBQklMSVRZIG9yIEZJVE5FU1MgRk9SIEEgUEFSVElDVUxBUiBQVVJQT1NFLiAgU2VlIHRoZSAgICAgICAgICAgKgorICogR05VIEdlbmVyYWwgUHVibGljIExpY2Vuc2UgZm9yIG1vcmUgZGV0YWlscy4gICAgICAgICAgICAgICAgICAgICAgICAgICAgKgorICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgorICogWW91IHNob3VsZCBoYXZlIHJlY2VpdmVkIGEgY29weSBvZiB0aGUgR05VIEdlbmVyYWwgUHVibGljIExpY2Vuc2UgICAgICAgKgorICogYWxvbmcgd2l0aCB0aGlzIHByb2dyYW07IGlmIG5vdCwgd3JpdGUgdG8gdGhlIEZyZWUgU29mdHdhcmUgICAgICAgICAgICAgKgorICogRm91bmRhdGlvbiwgSW5jLiwgNjc1IE1hc3MgQXZlLCBDYW1icmlkZ2UsIE1BIDAyMTM5LCBVU0EuICAgICAgICAgICAgICAgKgorICoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKi8KKworI2lmbmRlZiBfU045QzEwMl9DT05GSUdfSF8KKyNkZWZpbmUgX1NOOUMxMDJfQ09ORklHX0hfCisKKyNpbmNsdWRlIDxsaW51eC90eXBlcy5oPgorI2luY2x1ZGUgPGxpbnV4L2ppZmZpZ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TUsICA5OCwgMTEyLCAxMDAsIDEwMywgIDk5Cit9OworCitzdGF0aWMgY29uc3QgdTggU045QzEwMl9VVl9RVEFCTEUxWzY0XSA9IHsKKwkxNywgIDE4LCAgMjQsICA0NywgIDk5LCAgOTksICA5OSwgIDk5LAorCTE4LCAgMjEsICAyNiwgIDY2LCAgOTksICA5OSwgIDk5LCAgOTksCisJMjQsICAyNiwgIDU2LCAgOTksICA5OSwgIDk5LCAgOTksICA5OSwKKwk0NywgIDY2LCAgOTksICA5OSwgIDk5LCAgOTksICA5OSwgIDk5LAorCTk5LCAgOTksICA5OSwgIDk5LCAgOTksICA5OSwgIDk5LCAgOTksCisJOTksICA5OSwgIDk5LCAgOTksICA5OSwgIDk5LCAgOTksICA5OSwKKwk5OSwgIDk5LCAgOTksICA5OSwgIDk5LCAgOTksICA5OSwgIDk5LAorCTk5LCAgOTksICA5OSwgIDk5LCAgOTksICA5OSwgIDk5LCAgOTkKK307CisKKyNlbmRpZiAvKiBfU045QzEwMl9DT05GSUdfSF8gKi8KZGlmZiAtLWdpdCBhL2RyaXZlcnMvbWVkaWEvdmlkZW8vc245YzEwMi9zbjljMTAyX2NvcmUuYyBiL2RyaXZlcnMvbWVkaWEvdmlkZW8vc245YzEwMi9zbjljMTAyX2NvcmUuYwppbmRleCAxODQ1OGQ0Li5kMGUyYjQwIDEwMDY0NAotLS0gYS9kcml2ZXJzL21lZGlhL3ZpZGVvL3NuOWMxMDIvc245YzEwMl9jb3JlLmMKKysrIGIvZHJpdmVycy9tZWRpYS92aWRlby9zbjljMTAyL3NuOWMxMDJfY29yZS5jCkBAIC0xLDcgKzEsNyBAQAogLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKgotICogVjRMMiBkcml2ZXIgZm9yIFNOOUMxMHggUEMgQ2FtZXJhIENvbnRyb2xsZXJzICAgICAgICAgICAgICAgICAgICAgICAgICAgKgorICogVjRMMiBkcml2ZXIgZm9yIFNOOUMxeHggUEMgQ2FtZXJhIENvbnRyb2xsZXJzICAgICAgICAgICAgICAgICAgICAgICAgICAgKgogICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgotICogQ29weXJpZ2h0IChDKSAyMDA0LTIwMDYgYnkgTHVjYSBSaXNvbGlhIDxsdWNhLnJpc29saWFAc3R1ZGlvLnVuaWJvLml0PiAgKgorICogQ29weXJpZ2h0IChDKSAyMDA0LTIwMDcgYnkgTHVjYSBSaXNvbGlhIDxsdWNhLnJpc29saWFAc3R1ZGlvLnVuaWJvLml0PiAgKgogICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgogICogVGhpcyBwcm9ncmFtIGlzIGZyZWUgc29mdHdhcmU7IHlvdSBjYW4gcmVkaXN0cmlidXRlIGl0IGFuZC9vciBtb2RpZnkgICAgKgogICogaXQgdW5kZXIgdGhlIHRlcm1zIG9mIHRoZSBHTlUgR2VuZXJhbCBQdWJsaWMgTGljZW5zZSBhcyBwdWJsaXNoZWQgYnkgICAgKgpAQCAtNDMsMTIgKzQzLDEyIEBACiAKIC8qKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKi8KIAotI2RlZmluZSBTTjlDMTAyX01PRFVMRV9OQU1FICAgICAiVjRMMiBkcml2ZXIgZm9yIFNOOUMxMHggUEMgQ2FtZXJhIENvbnRyb2xsZXJzIgorI2RlZmluZSBTTjlDMTAyX01PRFVMRV9OQU1FICAgICAiVjRMMiBkcml2ZXIgZm9yIFNOOUMxeHggUEMgQ2FtZXJhIENvbnRyb2xsZXJzIgogI2RlZmluZSBTTjlDMTAyX01PRFVMRV9BVVRIT1IgICAiKEMpIDIwMDQtMjAwNiBMdWNhIFJpc29saWEiCiAj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TjlDMTAyX0ZSQU1FX1RJTUVPVVQpIi4iCiAJCSAiXG4iKTsKQEAgLTExMywzMiArMTE0LDEzIEBACiAKIC8qKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKi8KIAotc3RhdGljIHNuOWMxMDJfc29mX2hlYWRlcl90IHNuOWMxMDJfc29mX2hlYWRlcltdID0gewotCXsweGZmLCAweGZmLCAweDAwLCAweGM0LCAweGM0LCAweDk2LCAweDAwfSwKLQl7MHhmZiwgMHhmZiwgMHgwMCwgMHhjNCwgMHhjNCwgMHg5NiwgMHgwMX0sCi19OwotCi1zdGF0aWMgc245YzEwM19zb2ZfaGVhZGVyX3Qgc245YzEwM19zb2ZfaGVhZGVyW10gPSB7Ci0JezB4ZmYsIDB4ZmYsIDB4MDAsIDB4YzQsIDB4YzQsIDB4OTYsIDB4MjB9LAotfTsKLQotc3RhdGljIHNuOWMxMDJfZW9mX2hlYWRlcl90IHNuOWMxMDJfZW9mX2hlYWRlcltdID0gewotCXsweDAwLCAweDAwLCAweDAwLCAweDAwfSwKLQl7MHg0MCwgMHgwMCwgMHgwMCwgMHgwMH0sCi0JezB4ODAsIDB4MDAsIDB4MDAsIDB4MDB9LAotCXsweGMwLCAweDAwLCAweDAwLCAweDAwfSwKLX07Ci0KLS8qKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKi8KLQogc3RhdGljIHUzMgogc245YzEwMl9yZXF1ZXN0X2J1ZmZlcnMoc3RydWN0IHNuOWMxMDJfZGV2aWNlKiBjYW0sIHUzMiBjb3VudCwKIAkJCWVudW0gc245YzEwMl9pb19tZXRob2QgaW8pCiB7CiAJc3RydWN0IHY0bDJfcGl4X2Zvcm1hdCogcCA9ICYoY2FtLT5zZW5zb3IucGl4X2Zvcm1hdCk7CiAJc3RydWN0IHY0bDJfcmVjdCogciA9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3JlYWRfZXJyb3Ioc3RydWN0IHNuOWMxMDJfZGV2aWNlKiBjYW0sCiAJCQkgICAgICBzdHJ1Y3Qgc245YzEwMl9zZW5zb3IqIHNlbnNvcikKIHsKLQlpbnQgcjsKKwlpbnQgciAsIGVyciA9IDA7CisKIAlyID0gc245YzEwMl9yZWFkX3JlZyhjYW0sIDB4MDgpOwotCXJldHVybiAociA8IDAgfHwgKHIgPj0gMCAmJiAhKHIgJiAweDA4KSkpID8gLUVJTyA6IDA7CisJaWYgKHIgPCAwKQorCQllcnIgKz0gcjsKKworCWlmIChjYW0tPmJyaWRnZSA9PSBCUklER0VfU045QzEwMSB8fCBjYW0tPmJyaWRnZSA9PSBCUklER0VfU045QzEwMikgeworCQlpZiAoIShyICYgMHgwOCkpCisJCQllcnIgKz0gLTE7CisJfSBlbHNlIHsKKwkJaWYgKHIgJiAweDA4KQorCQkJZXJyICs9IC0xOworCX0KKworCXJldHVybiBlcnIgPyAtRUlPIDogMDsKIH0KIAogCkBAIC00MTUsNyArNDEzLDcgQEAKIAlkYXRhWzRdID0gZGF0YTM7CiAJZGF0YVs1XSA9IGRhdGE0OwogCWRhdGFbNl0gPSBkYXRhNTsKLQlkYXRhWzddID0gMHgxNDsKKwlkYXRhWzddID0gMHgxNzsKIAlyZXMgPSB1c2JfY29udHJvbF9tc2codWRldiwgdXNiX3NuZGN0cmxwaXBlKHVkZXYsIDApLCAweDA4LCAweDQxLAogCQkJICAgICAgMHgwOCwgMCwgZGF0YSwgOCwgU045QzEwMl9DVFJMX1RJTUVPVVQpOwogCWlmIChyZXMgPCAwKQpAQCAtNDY3LDMxICs0NjUsMzUgQEAKIAogLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqLwogCi1zdGF0aWMgdm9pZCoKLXNuOWMxMDJfZmluZF9zb2ZfaGVhZGVyKHN0cnVjdCBzbjljMTAyX2RldmljZSogY2FtLCB2b2lk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gpAQCAtODM0LDI5ICs5NTEsMjkgQEAKIC8qKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKi8KIAogI2lmZGVmIENPTkZJR19WSURFT19BRFZfREVCVUcKLXN0YXRpYyB1OCBzbjljMTAyX3N0cnRvdTgoY29uc3QgY2hhciogYnVmZiwgc2l6ZV90IGxlbiwgc3NpemVfdCogY291bnQpCitzdGF0aWMgdTE2IHNuOWMxMDJfc3RydG91MTYoY29uc3QgY2hhciogYnVmZiwgc2l6ZV90IGxlbiwgc3NpemVfdCogY291bnQpCiB7Ci0JY2hhciBzdHJbNV07CisJY2hhciBzdHJbN107CiAJY2hhciogZW5kcDsKIAl1bnNpZ25lZCBsb25nIHZhbDsKIAotCWlmIChsZW4gPCA0KSB7CisJaWYgKGxlbiA8IDYpIHsKIAkJc3RybmNweShzdHIsIGJ1ZmYsIGxlbik7CiAJCXN0cltsZW4rMV0gPSAnXDAnOwogCX0gZWxzZSB7CiAJCXN0cm5jcHkoc3RyLCBidWZmLCA0KTsKLQkJc3RyWzRdID0gJ1wwJzsKKwkJc3RyWzZdID0gJ1wwJzsKIAl9CiAKIAl2YWwgPSBzaW1wbGVfc3RydG91bChzdHIsICZlbmRwLCAwKTsKIAogCSpjb3VudCA9IDA7Ci0JaWYgKHZhbCA8PSAweGZmKQorCWlmICh2YWwgPD0gMHhmZmZmKQogCQkqY291bnQgPSAoc3NpemVfdCkoZW5kcCAtIHN0cik7CiAJaWYgKCgqY291bnQpICYmIChsZW4gPT0gKmNvdW50KzEpICYmIChidWZmWypjb3VudF0gPT0gJ1xuJykpCiAJCSpjb3VudCArPSAxOwogCi0JcmV0dXJuICh1OCl2YWw7CisJcmV0dXJuICh1MTYpdmFsOwogfQogCiAvKgpAQCAtODczLDcgKzk5MCw4IEBACiAJaWYgKG11dGV4X2xvY2tfaW50ZXJydXB0aWJsZSgmc245YzEwMl9zeXNmc19sb2NrKS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WYKLWZhaWwyOgotCXZpZGVvX25yW2Rldl9ucl0gPSAtMTsKLQlkZXZfbnIgPSAoZGV2X25yIDwgU045QzEwMl9NQVhfREVWSUNFUy0xKSA/IGRldl9ucisxIDogMDsKLQltdXRleF91bmxvY2soJmNhbS0+ZGV2X211dGV4KTsKIGZhaWw6CiAJaWYgKGNhbSkgewogCQlrZnJlZShjYW0tPmNvbnRyb2xfYnVmZmVyKTsKZGlmZiAtLWdpdCBhL2RyaXZlcnMvbWVkaWEvdmlkZW8vc245YzEwMi9zbjljMTAyX2RldnRhYmxlLmggYi9kcml2ZXJzL21lZGlhL3ZpZGVvL3NuOWMxMDIvc245YzEwMl9kZXZ0YWJsZS5oCm5ldyBmaWxlIG1vZGUgMTAwNjQ0CmluZGV4IDAwMDAwMDAuLjNhNjgyZWMKLS0tIC9kZXYvbnVsbAorKysgYi9kcml2ZXJzL21lZGlhL3ZpZGVvL3NuOWMxMDIvc245YzEwMl9kZXZ0YWJsZS5oCkBAIC0wLDAgKzEsMTQyIEBACisvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqCisgKiBUYWJsZSBvZiBkZXZpY2UgaWRlbnRpZmllcnMgb2YgdGhlIFNOOUMxeHggUEMgQ2FtZXJhIENvbnRyb2xsZXJzICAgICAgICAqCisgKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCisgKiBDb3B5cmlnaHQgKEMpIDIwMDcgYnkgTHVjYSBSaXNvbGlhIDxsdWNhLnJpc29saWFAc3R1ZGlvLnVuaWJvLml0PiAgICAgICAqCisgKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCisgKiBUaGlzIHByb2dyYW0gaXMgZnJlZSBzb2Z0d2FyZTsgeW91IGNhbiByZWRpc3RyaWJ1dGUgaXQgYW5kL29yIG1vZGlmeSAgICAqCisgKiBpdCB1bmRlciB0aGUgdGVybXMgb2YgdGhlIEdOVSBHZW5lcmFsIFB1YmxpYyBMaWNlbnNlIGFzIHB1Ymxpc2hlZCBieSAgICAqCisgKiB0aGUgRnJlZSBTb2Z0d2FyZSBGb3VuZGF0aW9uOyBlaXRoZXIgdmVyc2lvbiAyIG9mIHRoZSBMaWNlbnNlLCBvciAgICAgICAqCisgKiAoYXQgeW91ciBvcHRpb24pIGFueSBsYXRlciB2ZXJzaW9uLiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCisgKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCisgKiBUaGlzIHByb2dyYW0gaXMgZGlzdHJpYnV0ZWQgaW4gdGhlIGhvcGUgdGhhdCBpdCB3aWxsIGJlIHVzZWZ1bCwgICAgICAgICAqCisgKiBidXQgV0lUSE9VVCBBTlkgV0FSUkFOVFk7IHdpdGhvdXQgZXZlbiB0aGUgaW1wbGllZCB3YXJyYW50eSBvZiAgICAgICAgICAqCisgKiBNRVJDSEFOVEFCSUxJVFkgb3IgRklUTkVTUyBGT1IgQSBQQVJUSUNVTEFSIFBVUlBPU0UuICBTZWUgdGhlICAgICAgICAgICAqCisgKiBHTlUgR2VuZXJhbCBQdWJsaWMgTGljZW5zZSBmb3IgbW9yZSBkZXRhaWxzLiAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCisgKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCisgKiBZb3Ugc2hvdWxkIGhhdmUgcmVjZWl2ZWQgYSBjb3B5IG9mIHRoZSBHTlUgR2VuZXJhbCBQdWJsaWMgTGljZW5zZSAgICAgICAqCisgKiBhbG9uZyB3aXRoIHRoaXMgcHJvZ3JhbTsgaWYgbm90LCB3cml0ZSB0byB0aGUgRnJlZSBTb2Z0d2FyZSAgICAgICAgICAgICAqCisgKiBGb3VuZGF0aW9uLCBJbmMuLCA2NzUgTWFzcyBBdmUsIENhbWJyaWRnZSwgTUEgMDIxMzksIFVTQS4gICAgICAgICAgICAgICAqCisgKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqLworCisjaWZuZGVmIF9TTjlDMTAyX0RFVlRBQkxFX0hfCisjZGVmaW5lIF9TTjlDMTAyX0RFVlRBQkxFX0hfCisKKyNpbmNsdWRlIDxsaW51eC91c2IuaD4KKworc3RydWN0IHNuOWMxMDJfZGV2aWNlOworCisvKgorICAgRWFjaCBTTjlDMXh4IGNhbWVyYSBoYXMgcHJvcGVyIFBJRC9WSUQgaWRlbnRpZmllcnMuCisgICBTTjlDMTAzLCBTTjlDMTA1LCBTTjlDMTIwIHN1cHBvcnQgbXVsdGlwbGUgaW50ZXJmYWNlcywgYnV0IHdlIG9ubHkgaGF2ZSB0bworICAgaGFuZGxlIHRoZSB2aWRlbyBjbGFzcyBpbnRlcmZhY2UuCisqLworI2RlZmluZSBTTjlDMTAyX1VTQl9ERVZJQ0UodmVuZCwgcHJvZCwgYnJpZGdlKSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgXAorCS5tYXRjaF9mbGFncyA9IFVTQl9ERVZJQ0VfSURfTUFUQ0hfREVWSUNFIHwgICAgICAgICAgICAgICAgICAgICAgICAgICBcCisJCSAgICAgICBVU0JfREVWSUNFX0lEX01BVENIX0lOVF9DTEFTUywgICAgICAgICAgICAgICAgICAgICAgICAgXAorCS5pZFZlbmRvciA9ICh2ZW5kKSwgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBcCisJLmlkUHJvZHVjdCA9IChwcm9kKSwgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFwKKwkuYk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Ml9odjcxMzFkLmMKQEAgLTEsOCArMSw4IEBACiAvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqCi0gKiBQbHVnLWluIGZvciBIVjcxMzFEIGltYWdlIHNlbnNvciBjb25uZWN0ZWQgdG8gdGhlIFNOOUMxMHggUEMgQ2FtZXJhICAgICAqCisgKiBQbHVnLWluIGZvciBIVjcxMzFEIGltYWdlIHNlbnNvciBjb25uZWN0ZWQgdG8gdGhlIFNOOUMxeHggUEMgQ2FtZXJhICAgICAqCiAgKiBDb250cm9sbGVycyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCiAgKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCi0gKiBDb3B5cmlnaHQgKEMpIDIwMDQtMjAwNiBieSBMdWNhIFJpc29saWEgPGx1Y2Eucmlzb2xpYUBzdHVkaW8udW5pYm8uaXQ+ICAqCisgKiBDb3B5cmlnaHQgKEMpIDIwMDQtMjAwNyBieSBMdWNhIFJpc29saWEgPGx1Y2Eucmlzb2xpYUBzdHVkaW8udW5pYm8uaXQ+ICAqCiAgKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCiAgKiBUaGlzIHByb2dyYW0gaXMgZnJlZSBzb2Z0d2FyZTsgeW91IGNhbiByZWRpc3RyaWJ1dGUgaXQgYW5kL29yIG1vZGlmeSAgICAqCiAgKiBpdCB1bmRlciB0aGUgdGVybXMgb2YgdGhlIEdOVSBHZW5lcmFsIFB1YmxpYyBMaWNlbnNlIGFzIHB1Ymxpc2hlZCBieSAgICAqCkBAIC0xMjQsNyArMTI0LDcgQEAKIHN0YXRpYyBpbnQgaHY3MTMxZF9zZXRfY3JvcChzdHJ1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xMDJfbWkwMzQzLmMKKysrIGIvZHJpdmVycy9tZWRpYS92aWRlby9zbjljMTAyL3NuOWMxMDJfbWkwMzQzLmMKQEAgLTEsOCArMSw4IEBACiAvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqCi0gKiBQbHVnLWluIGZvciBNSS0wMzQzIGltYWdlIHNlbnNvciBjb25uZWN0ZWQgdG8gdGhlIFNOOUMxMHggUEMgQ2FtZXJhICAgICAqCisgKiBQbHVnLWluIGZvciBNSS0wMzQzIGltYWdlIHNlbnNvciBjb25uZWN0ZWQgdG8gdGhlIFNOOUMxeHggUEMgQ2FtZXJhICAgICAqCiAgKiBDb250cm9sbGVycyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCiAgKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCi0gKiBDb3B5cmlnaHQgKEMpIDIwMDQtMjAwNiBieSBMdWNhIFJpc29saWEgPGx1Y2Eucmlzb2xpYUBzdHVkaW8udW5pYm8uaXQ+ICAqCisgKiBDb3B5cmlnaHQgKEMpIDIwMDQtMjAwNyBieSBMdWNhIFJpc29saWEgPGx1Y2Eucmlzb2xpYUBzdHVkaW8udW5pYm8uaXQ+ICAqCiAgKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCiAgKiBUaGlzIHByb2dyYW0gaXMgZnJlZSBzb2Z0d2FyZTsgeW91IGNhbiByZWRpc3RyaWJ1dGUgaXQgYW5kL29yIG1vZGlmeSAgICAqCiAgKiBpdCB1bmRlciB0aGUgdGVybXMgb2YgdGhlIEdOVSBHZW5lcmFsIFB1YmxpYyBMaWNlbnNlIGFzIHB1Ymxpc2hlZCBieSAgICAqCkBAIC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2RyaXZlcnMvbWVkaWEvdmlkZW8vc245YzEwMi9zbjljMTAyX292NzYzMC5jCisrKyBiL2RyaXZlcnMvbWVkaWEvdmlkZW8vc245YzEwMi9zbjljMTAyX292NzYzMC5jCkBAIC0xLDggKzEsOCBAQAogLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKgotICogUGx1Zy1pbiBmb3IgT1Y3NjMwIGltYWdlIHNlbnNvciBjb25uZWN0ZWQgdG8gdGhlIFNOOUMxMHggUEMgQ2FtZXJhICAgICAgKgorICogUGx1Zy1pbiBmb3IgT1Y3NjMwIGltYWdlIHNlbnNvciBjb25uZWN0ZWQgdG8gdGhlIFNOOUMxeHggUEMgQ2FtZXJhICAgICAgKgogICogQ29udHJvbGxlcnMgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgogICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgotICogQ29weXJpZ2h0IChDKSAyMDA1LTIwMDYgYnkgTHVjYSBSaXNvbGlhIDxsdWNhLnJpc29saWFAc3R1ZGlvLnVuaWJvLml0PiAgKgorICogQ29weXJpZ2h0IChDKSAyMDA2LTIwMDcgYnkgTHVjYSBSaXNvbGlhIDxsdWNhLnJpc29saWFAc3R1ZGlvLnVuaWJvLml0PiAgKgogICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgogICogVGhpcyBwcm9ncmFtIGlzIGZyZWUgc29mdHdhcmU7IHlvdSBjYW4gcmVkaXN0cmlidXRlIGl0IGFuZC9vciBtb2RpZnkgICAgKgogICogaXQgdW5kZXIgdGhlIHRlcm1zIG9mIHRoZSBHTlUgR2VuZXJhbCBQdWJsaWMgTGljZW5zZSBhcyBwdWJsa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2NDQKaW5kZXggMDAwMDAwMC4uZDY3MGMyNAotLS0gL2Rldi9udWxsCisrKyBiL2RyaXZlcnMvbWVkaWEvdmlkZW8vc245YzEwMi9zbjljMTAyX292NzY2MC5jCkBAIC0wLDAgKzEsNTkyIEBACisvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqCisgKiBQbHVnLWluIGZvciBPVjc2NjAgaW1hZ2Ugc2Vuc29yIGNvbm5lY3RlZCB0byB0aGUgU045QzF4eCBQQyBDYW1lcmEgICAgICAqCisgKiBDb250cm9sbGVycyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCisgKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCisgKiBDb3B5cmlnaHQgKEMpIDIwMDcgYnkgTHVjYSBSaXNvbGlhIDxsdWNhLnJpc29saWFAc3R1ZGlvLnVuaWJvLml0PiAgICAgICAqCisgKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCisgKiBUaGlzIHByb2dyYW0gaXMgZnJlZSBzb2Z0d2FyZTsgeW91IGNhbiByZWRpc3RyaWJ1dGUgaXQgYW5kL29yIG1vZGlmeSAgICAqCisgKiBpdCB1bmRlciB0aGUgdGVybXMgb2YgdGhlIEdOVSBHZW5lcmFsIFB1YmxpYyBMaWNlbnNlIGFzIHB1Ymxpc2hlZCBieSAgICAqCisgKiB0aGUgRnJlZSBTb2Z0d2FyZSBGb3VuZGF0aW9uOyBlaXRoZXIgdmVyc2lvbiAyIG9mIHRoZSBMaWNlbnNlLCBvciAgICAgICAqCisgKiAoYXQgeW91ciBvcHRpb24pIGFueSBsYXRlciB2ZXJzaW9uLiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCisgKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCisgKiBUaGlzIHByb2dyYW0gaXMgZGlzdHJpYnV0ZWQgaW4gdGhlIGhvcGUgdGhhdCBpdCB3aWxsIGJlIHVzZWZ1bCwgICAgICAgICAqCisgKiBidXQgV0lUSE9VVCBBTlkgV0FSUkFOVFk7IHdpdGhvdXQgZXZlbiB0aGUgaW1wbGllZCB3YXJyYW50eSBvZiAgICAgICAgICAqCisgKiBNRVJDSEFOVEFCSUxJVFkgb3IgRklUTkVTUyBGT1IgQSBQQVJUSUNVTEFSIFBVUlBPU0UuICBTZWUgdGhlICAgICAgICAgICAqCisgKiBHTlUgR2VuZXJhbCBQdWJsaWMgTGljZW5zZSBmb3IgbW9yZSBkZXRhaWxzLiAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCisgKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCisgKiBZb3Ugc2hvdWxkIGhhdmUgcmVjZWl2ZWQgYSBjb3B5IG9mIHRoZSBHTlUgR2VuZXJhbCBQdWJsaWMgTGljZW5zZSAgICAgICAqCisgKiBhbG9uZyB3aXRoIHRoaXMgcHJvZ3JhbTsgaWYgbm90LCB3cml0ZSB0byB0aGUgRnJlZSBTb2Z0d2FyZSAgICAgICAgICAgICAqCisgKiBGb3VuZGF0aW9uLCBJbmMuLCA2NzUgTWFzcyBBdmUsIENhbWJyaWRnZSwgTUEgMDIxMzksIFVTQS4gICAgICAgICAgICAgICAqCisgKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqLworCisjaW5jbHVkZSAic245YzEwMl9zZW5zb3IuaCIKKworCitzdGF0aWMgc3RydWN0IHNuOWMxMDJfc2Vuc29yIG92NzY2MDsKK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LCAmb3Y3NjYwLCAweDBiKTsKKwlpZiAoZXJyIHx8IHBpZCA8IDAgfHwgdmVyIDwgMCkKKwkJcmV0dXJuIC1FSU87CisJaWYgKHBpZCAhPSAweDc2IHx8IHZlciAhPSAweDYwKQorCQlyZXR1cm4gLUVOT0RFVjsKKwlzbjljMTAyX2F0dGFjaF9zZW5zb3IoY2FtLCAmb3Y3NjYwKTsKKworCXJldHVybiAwOworfQpkaWZmIC0tZ2l0IGEvZHJpdmVycy9tZWRpYS92aWRlby9zbjljMTAyL3NuOWMxMDJfcGFzMTA2Yi5jIGIvZHJpdmVycy9tZWRpYS92aWRlby9zbjljMTAyL3NuOWMxMDJfcGFzMTA2Yi5jCmluZGV4IDk5MTU5NDQuLjhkNzlhNWYgMTAwNjQ0Ci0tLSBhL2RyaXZlcnMvbWVkaWEvdmlkZW8vc245YzEwMi9zbjljMTAyX3BhczEwNmIuYworKysgYi9kcml2ZXJzL21lZGlhL3ZpZGVvL3NuOWMxMDIvc245YzEwMl9wYXMxMDZiLmMKQEAgLTEsOCArMSw4IEBACiAvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqCi0gKiBQbHVnLWluIGZvciBQQVMxMDZCIGltYWdlIHNlbnNvciBjb25uZWN0ZWQgdG8gdGhlIFNOOUMxMHggUEMgQ2FtZXJhICAgICAqCisgKiBQbHVnLWluIGZvciBQQVMxMDZCIGltYWdlIHNlbnNvciBjb25uZWN0ZWQgdG8gdGhlIFNOOUMxeHggUEMgQ2FtZXJhICAgICAqCiAgKiBDb250cm9sbGVycyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCiAgKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCi0gKiBDb3B5cmlnaHQgKEMpIDIwMDQtMjAwNiBie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hIFJpc29saWEgPGx1Y2Eucmlzb2xpYUBzdHVkaW8udW5pYm8uaXQ+IiwKKwkuc3VwcG9ydGVkX2JyaWRnZSA9IEJSSURHRV9TTjlDMTAxIHwgQlJJREdFX1NOOUMxMDIgfCBCUklER0VfU045QzEwMywKIAkuc3lzZnNfb3BzID0gU045QzEwMl9JMkNfUkVBRCB8IFNOOUMxMDJfSTJDX1dSSVRFLAogCS5mcmVxdWVuY3kgPSBTTjlDMTAyX0kyQ180MDBLSFogfCBTTjlDMTAyX0kyQ18xMDBLSFosCiAJLmludGVyZmFjZSA9IFNOOUMxMDJfSTJDXzJXSVJFUywKZGlmZiAtLWdpdCBhL2RyaXZlcnMvbWVkaWEvdmlkZW8vc245YzEwMi9zbjljMTAyX3BhczIwMmJjYS5jIGIvZHJpdmVycy9tZWRpYS92aWRlby9zbjljMTAyL3NuOWMxMDJfcGFzMjAyYmNhLmMKZGVsZXRlZCBmaWxlIG1vZGUgMTAwNjQ0CmluZGV4IGM4ZjFhZTIuLjAwMDAwMDAKLS0tIGEvZHJpdmVycy9tZWRpYS92aWRlby9zbjljMTAyL3NuOWMxMDJfcGFzMjAyYmNhLmMKKysrIC9kZXYvbnVsbApAQCAtMSwyMzggKzAsMCBAQAotLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKgotICogUGx1Zy1pbiBmb3IgUEFTMjAyQkNBIGltYWdlIHNlbnNvciBjb25uZWN0ZWQgdG8gdGhlIFNOOUMxMHggUEMgQ2FtZXJhICAgKgotICogQ29udHJvbGxlcnMgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgotICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgotICogQ29weXJpZ2h0IChDKSAyMDA2IGJ5IEx1Y2EgUmlzb2xpYSA8bHVjYS5yaXNvbGlhQHN0dWRpby51bmliby5pdD4gICAgICAgKgotICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgotICogVGhpcyBwcm9ncmFtIGlzIGZyZWUgc29mdHdhcmU7IHlvdSBjYW4gcmVkaXN0cmlidXRlIGl0IGFuZC9vciBtb2RpZnkgICAgKgotICogaXQgdW5kZXIgdGhlIHRlcm1zIG9mIHRoZSBHTlUgR2VuZXJhbCBQdWJsaWMgTGljZW5zZSBhcyBwdWJsaXNoZWQgYnkgICAgKgotICogdGhlIEZyZWUgU29mdHdhcmUgRm91bmRhdGlvbjsgZWl0aGVyIHZlcnNpb24gMiBvZiB0aGUgTGljZW5zZSwgb3IgICAgICAgKgotICogKGF0IHlvdXIgb3B0aW9uKSBhbnkgbGF0ZXIgdmVyc2lvbi4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgotICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgotICogVGhpcyBwcm9ncmFtIGlzIGRpc3RyaWJ1dGVkIGluIHRoZSBob3BlIHRoYXQgaXQgd2lsbCBiZSB1c2VmdWwsICAgICAgICAgKgotICogYnV0IFdJVEhPVVQgQU5ZIFdBUlJBTlRZOyB3aXRob3V0IGV2ZW4gdGhlIGltcGxpZWQgd2FycmFudHkgb2YgICAgICAgICAgKgotICogTUVSQ0hBTlRBQklMSVRZIG9yIEZJVE5FU1MgRk9SIEEgUEFSVElDVUxBUiBQVVJQT1NFLiAgU2VlIHRoZSAgICAgICAgICAgKgotICogR05VIEdlbmVyYWwgUHVibGljIExpY2Vuc2UgZm9yIG1vcmUgZGV0YWlscy4gICAgICAgICAgICAgICAgICAgICAgICAgICAgKgotICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICA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wMi9zbjljMTAyX3BhczIwMmJjYi5jCkBAIC0xLDEzICsxLDEzIEBACiAvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqCi0gKiBQbHVnLWluIGZvciBQQVMyMDJCQ0IgaW1hZ2Ugc2Vuc29yIGNvbm5lY3RlZCB0byB0aGUgU045QzEweCBQQyBDYW1lcmEgICAqCisgKiBQbHVnLWluIGZvciBQQVMyMDJCQ0IgaW1hZ2Ugc2Vuc29yIGNvbm5lY3RlZCB0byB0aGUgU045QzF4eCBQQyBDYW1lcmEgICAqCiAgKiBDb250cm9sbGVycyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCiAgKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCiAgKiBDb3B5cmlnaHQgKEMpIDIwMDQgYnkgQ2FybG9zIEVkdWFyZG8gTWVkYWdsaWEgRHlvbmlzaW8gICAgICAgICAgICAgICAgICAqCiAgKiAgICAgICAgICAgICAgICAgICAgICAgPG1lZGFnbGlhQHVuZGwub3JnLmJyPiAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCiAgKiAgICAgICAgICAgICAgICAgICAgICAgaHR0cDovL2NhZHUuaG9tZWxpbnV4LmNvbTo4MDgwLyAgICAgICAgICAgICAgICAgICAqCiAgKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCi0gKiBEQUMgTWFnbml0dWRlLCBleHBvc3VyZSBhbmQgZ3JlZW4gZ2FpbiBjb250cm9scyBhZGRlZCBieSAgICAgICAgICAgICAgICAqCi0gKiBMdWNhIFJpc29saWEgPGx1Y2Eucmlzb2xpYUBzdHVkaW8udW5pYm8uaXQ+ICAgICAgICAgICAgICAgICAgICAg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0aGUgU045QzEweCBQQyBDYW1lcmEgQ29udHJvbGxlcnMgICAgKgorICogQVBJIGZvciBpbWFnZSBzZW5zb3JzIGNvbm5lY3RlZCB0byB0aGUgU045QzF4eCBQQyBDYW1lcmEgQ29udHJvbGxlcnMgICAgKgogICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgotICogQ29weXJpZ2h0IChDKSAyMDA0LTIwMDYgYnkgTHVjYSBSaXNvbGlhIDxsdWNhLnJpc29saWFAc3R1ZGlvLnVuaWJvLml0PiAgKgorICogQ29weXJpZ2h0IChDKSAyMDA0LTIwMDcgYnkgTHVjYSBSaXNvbGlhIDxsdWNhLnJpc29saWFAc3R1ZGlvLnVuaWJvLml0PiAgKgogICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgogICogVGhpcyBwcm9ncmFtIGlzIGZyZWUgc29mdHdhcmU7IHlvdSBjYW4gcmVkaXN0cmlidXRlIGl0IGFuZC9vciBtb2RpZnkgICAgKgogICogaXQgdW5kZXIgdGhlIHRlcm1zIG9mIHRoZSBHTlUgR2VuZXJhbCBQdWJsaWMgTGljZW5zZSBhcyBwdWJsaXNoZWQgYnkgICAgKgpAQCAtMzYsMTQgKzM2LDEzIEBACiAvKgogICAgT1ZFUlZJRVcuCiAgICBUaGlzIGlzIGEgc21hbGwgaW50ZXJmYWNlIHRoYXQgYWxsb3dzIHlvdSB0byBhZGQgc3VwcG9ydCBmb3IgYW55IENDRC9DTU9TCi0gICBpbWFnZSBzZW5zb3JzIGNvbm5lY3RlZCB0byB0aGUgU045QzEwWCBicmlkZ2VzLiBUaGUgZW50aXJlIEFQSSBpcyBkb2N1bWVudGVkCisgICBpbWFnZSBzZW5zb3JzIGNvbm5lY3RlZCB0byB0aGUgU045QzFYWCBicmlkZ2VzLiBUaGUgZW50aXJlIEFQSSBpcy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fZGV2aWNlX2lkICppZCk7CiAKQEAgLTk5LDY4ICs3Nyw4IEBACiAJCSAgICAgIHN0cnVjdCBzbjljMTAyX3NlbnNvciogc2Vuc29yKTsKIAogLyoKLSAgIEVhY2ggU045QzEweCBjYW1lcmEgaGFzIHByb3BlciBQSUQvVklEIGlkZW50aWZpZXJzLgotICAgU045QzEwMyBzdXBwb3J0cyBtdWx0aXBsZSBpbnRlcmZhY2VzLCBidXQgd2Ugb25seSBoYW5kbGUgdGhlIHZpZGVvIGNsYXNzCi0gICBpbnRlcmZhY2UuCi0qLwotI2RlZmluZSBTTjlDMTAyX1VTQl9ERVZJQ0UodmVuZCwgcHJvZCwgaW50Y2xhc3MpICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgXAotCS5tYXRjaF9mbGFncyA9IFVTQl9ERVZJQ0VfSURfTUFUQ0hfREVWSUNFIHwgICAgICAgICAgICAgICAgICAgICAgICAgICBcCi0JCSAgICAgICBVU0JfREVWSUNFX0lEX01BVENIX0lOVF9DTEFTUywgICAgICAgICAgICAgICAgICAgICAgICAgXAotCS5pZFZlbmRvciA9ICh2ZW5kKSwgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBcCi0JLmlkUHJvZHVjdCA9IChwcm9kKSwgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFwKLQkuYkludGVyZmFjZUNsYXNzID0gKGludGNsYXNzKQotCi0jZGVmaW5lIFNOOUMxMDJfSURfVEFCTEUgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBcCi1zdGF0aWMgY29uc3Qgc3RydWN0IHVzYl9kZXZpY2VfaWQgc245YzEwMl9pZF90YWJsZVtdID0geyAgICAgICAgICAgICAgICAgICAgICBcCi0JeyBVU0JfREVWSUNFKDB4MGM0NSwgMHg2MDAxKSwgfSwgLyogVEFTNTExMEMxQiAqLyAgICAgICAgICAgICAgICAgICAgIFwKLQl7IFVTQl9ERVZJQ0UoMHgwYzQ1LCAweDYwMDUpLCB9LCAvKiBUQVM1MTEwQzFCICovICAgICAgICAgICAgICAgICAgICAgXAotCXsgVVNCX0RFVklDRSgweDBjNDUsIDB4NjAwNyksIH0sICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBcCi0JeyBVU0JfREVWSUNFKDB4MGM0NSwgMHg2MDA5KSwgfSwgLyogUEFTMTA2QiAqLyAgICAgICAgICAgICAgICAgICAgICAgIFwKLQl7IFVTQl9ERVZJQ0UoMHgwYzQ1LCAweDYwMGQpLCB9LCAvKiBQQVMxMDZCICovICAgICAgICAgICAgICAgICAgICAgICAgXAotCXsgVVNCX0RFVklDRSgweDBjNDUsIDB4NjAyNCksIH0sICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBcCi0JeyBVU0JfREVWSUNFKDB4MGM0NSwgMHg2MDI1KSwgfSwgLyogVEFTNTEzMEQxQiBhbmQgVEFTNTExMEMxQiAqLyAgICAgIFwKLQl7IFVTQl9ERVZJQ0UoMHgwYzQ1LCAweDYwMjgpLCB9LCAvKiBQQVMyMDJCQ0IgKi8gICAgICAgICAgICAgICAgICAgICAgXAotCXsgVVNCX0RFVklDRSgweDBjNDUsIDB4NjAyOSksIH0sIC8qIFBBUzEwNkIgKi8gICAgICAgICAgICAgICAgICAgICAgICBcCi0JeyBVU0JfREVWSUNFKDB4MGM0NSwgMHg2MDJhKSwgfSwgLyogSFY3MTMxRCAqLyAgICAgICAgICAgICAgICAgICAgICAgIFwKLQl7IFVTQl9ERVZJQ0UoMHgwYzQ1LCAweDYwMmIpLCB9LCAvKiBNSS0wMzQzICovICAgICAgICAgICAgICAgICAgICAgICAgXAotCXsgVVNCX0RFVklDRSgweDBjNDUsIDB4NjAyYyksIH0sIC8qIE9WNzYzMCAqLyAgICAgICAgICAgICAgICAgICAgICAgICBcCi0JeyBVU0JfREVWSUNFKDB4MGM0NSwgMHg2MDJkKSwgfSw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l9VU0JfREVWSUNFKDB4MGM0NSwgMHg2MGIzLCAweGZmKSwgfSwgICAgICAgICAgICAgICAgICAgICAgICBcCi0JeyBTTjlDMTAyX1VTQl9ERVZJQ0UoMHgwYzQ1LCAweDYwYjgsIDB4ZmYpLCB9LCAgICAgICAgICAgICAgICAgICAgICAgIFwKLQl7IFNOOUMxMDJfVVNCX0RFVklDRSgweDBjNDUsIDB4NjBiYSwgMHhmZiksIH0sICAgICAgICAgICAgICAgICAgICAgICAgXAotCXsgU045QzEwMl9VU0JfREVWSUNFKDB4MGM0NSwgMHg2MGJiLCAweGZmKSwgfSwgICAgICAgICAgICAgICAgICAgICAgICBcCi0JeyBTTjlDMTAyX1VTQl9ERVZJQ0UoMHgwYzQ1LCAweDYwYmMsIDB4ZmYpLCB9LCAgICAgICAgICAgICAgICAgICAgICAgIFwKLQl7IFNOOUMxMDJfVVNCX0RFVklDRSgweDBjNDUsIDB4NjBiZSwgMHhmZiksIH0sICAgICAgICAgICAgICAgICAgICAgICAgXAotCXsgfSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBcCi19OwotCi0vKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiovCi0KLS8qCiAgICBSZWFkL3dyaXRlIHJvdXRpbmVzOiB0aGV5IGFsd2F5cyByZXR1cm4gLTEgb24gZXJyb3IsIDAgb3IgdGhlIHJlYWQgdmFsdWUKLSAgIG90aGVyd2lzZS4gTk9URSB0aGF0IGEgcmVhbCByZWFkIG9wZXJhdGlvbiBpcyBub3Qgc3VwcG9ydGVkIGJ5IHRoZSBTTjlDMTBYCisgICBvdGhlcndpc2UuIE5PVEUgdGhhdCBhIHJlYWwgcmVhZCBvcGVyYXRpb24gaXMgbm90IHN1cHBvcnRlZCBieSB0aGUgU045QzFYWAogICAgY2hpcCBmb3Igc29tZSBvZiBpdHM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yX3RhczUxMzBkMWIuYworKysgYi9kcml2ZXJzL21lZGlhL3ZpZGVvL3NuOWMxMDIvc245YzEwMl90YXM1MTMwZDFiLmMKQEAgLTEsOCArMSw4IEBACiAvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqCi0gKiBQbHVnLWluIGZvciBUQVM1MTMwRDFCIGltYWdlIHNlbnNvciBjb25uZWN0ZWQgdG8gdGhlIFNOOUMxMHggUEMgQ2FtZXJhICAqCisgKiBQbHVnLWluIGZvciBUQVM1MTMwRDFCIGltYWdlIHNlbnNvciBjb25uZWN0ZWQgdG8gdGhlIFNOOUMxeHggUEMgQ2FtZXJhICAqCiAgKiBDb250cm9sbGVycyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCiAgKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCi0gKiBDb3B5cmlnaHQgKEMpIDIwMDQtMjAwNiBieSBMdWNhIFJpc29saWEgPGx1Y2Eucmlzb2xpYUBzdHVkaW8udW5pYm8uaXQ+ICAqCisgKiBDb3B5cmlnaHQgKEMpIDIwMDQtMjAwNyBieSBMdWNhIFJpc29saWEgPGx1Y2Eucmlzb2xpYUBzdHVkaW8udW5pYm8uaXQ+ICAqCiAgKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCiAgKiBUaGlzIHByb2dyYW0gaXMgZnJlZSBzb2Z0d2FyZTsgeW91IGNhbiByZWRpc3RyaWJ1dGUgaXQgYW5kL29yIG1vZGlmeSAgICAqCiAgKiBpdCB1bmRlciB0aGUgdGVybXMgb2YgdGhlIEdOVSBHZW5lcmFsIFB1YmxpYyBMaWNlbnNlIGFzIHB1Ymxpc2hlZCBieSAgIC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L3ZpZGVvL3pjMDMwMS96YzAzMDEuaApAQCAtMSw3ICsxLDcgQEAKIC8qKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioKLSAqIFY0TDIgZHJpdmVyIGZvciBaQzAzMDEgSW1hZ2UgUHJvY2Vzc29yIGFuZCBDb250cm9sIENoaXAgICAgICAgICAgICAgICAgICoKKyAqIFY0TDIgZHJpdmVyIGZvciBaQzAzMDFbUF0gSW1hZ2UgUHJvY2Vzc29yIGFuZCBDb250cm9sIENoaXAgICAgICAgICAgICAgICoKICAqICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICoKLSAqIENvcHlyaWdodCAoQykgMjAwNiBieSBMdWNhIFJpc29saWEgPGx1Y2Eucmlzb2xpYUBzdHVkaW8udW5pYm8uaXQ+ICAgICAgICoKKyAqIENvcHlyaWdodCAoQykgMjAwNi0yMDA3IGJ5IEx1Y2EgUmlzb2xpYSA8bHVjYS5yaXNvbGlhQHN0dWRpby51bmliby5pdD4gICoKICAqICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICoKICAqIFRoaXMgcHJvZ3JhbSBpcyBmcmVlIHNvZnR3YXJlOyB5b3UgY2FuIHJlZGlzdHJpYnV0ZSBpdCBhbmQvb3IgbW9kaWZ5ICAgICoKICAqIGl0IHVuZGVyIHRoZSB0ZXJtcyBvZiB0aGUgR05VIEdlbmVyYWwgUHVibGljIExpY2Vuc2UgYXMgcHVibGlzaGVkIGJ5ICAgICoKZGlmZiAtLWdpdCBhL2RyaXZlcnMvbWVkaWEvdmlkZW8vemMwMzAxL3pjMDMwMV9jb3JlLmMgYi9kcml2ZXJzL21lZGlhL3ZpZGVvL3pjMDMwMS96YzAzMDFfY29yZS5jCmluZGV4IDUyZDBmNzUuLmYxMTIwNTUgMTAwNjQ0Ci0tLSBhL2RyaXZlcnMvbWVkaWEvdmlkZW8vemMwMzAxL3pjMDMwMV9jb3JlLmMKKysrIGIvZHJpdmVycy9tZWRpYS92aWRlby96YzAzMDEvemMwMzAxX2NvcmUuYwpAQCAtMSw3ICsxLDcgQEAKIC8qKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioKICAqIFZpZGVvNExpbnV4MiBkcml2ZXIgZm9yIFpDMDMwMVtQXSBJbWFnZSBQcm9jZXNzb3IgYW5kIENvbnRyb2wgQ2hpcCAgICAgICoKICAqICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICoKLSAqIENvcHlyaWdodCAoQykgMjAwNiBieSBMdWNhIFJpc29saWEgPGx1Y2Eucmlzb2xpYUBzdHVkaW8udW5pYm8uaXQ+ICAgICAgICoKKyAqIENvcHlyaWdodCAoQykgMjAwNi0yMDA3IGJ5IEx1Y2EgUmlzb2xpYSA8bHVjYS5yaXNvbGlhQHN0dWRpby51bmliby5pdD4gICoKICAqICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICoKICAqIEluZm9ybWF0aW9ucyBhYm91dCB0aGUgY2hpcCBpbnRlcm5hbHMgbmVlZGVkIHRvIGVuYWJsZSB0aGUgSTJDIHByb3RvY29sICoKICAqIGhhdmUgYmVlbiB0YWtlbiBmcm9tIHRoZSBkb2N1bWVudGF0aW9uIG9mIHRoZSBaQzAzMHggVmlkZW80TGludXgxICAgICAgICoKQEAgLTUyLDggKzUyLDggQEAKICNkZWZpbmUgWkMwMzAxX01PRFVMRV9BVVRIT1IgICIoQykgMjAwNiBMdWNhIFJpc29saWEiCiAjZGVmaW5lIFpDMDMwMV9BVVRIT1JfRU1BSUwgICAiPGx1Y2Euc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3IgUEFTMjAyQkNCIGltYWdlIHNlbnNvciBjb25uZWN0ZWQgdG8gdGhlIFpDMDMwMVtQXSBJbWFnZSAgICAgKgorICogUGx1Zy1pbiBmb3IgUEFTMjAyQkNCIGltYWdlIHNlbnNvciBjb25uZWN0ZWQgdG8gdGhlIFpDMDMwMSBJbWFnZSAgICAgICAgKgogICogUHJvY2Vzc29yIGFuZCBDb250cm9sIENoaXAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgogICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgotICogQ29weXJpZ2h0IChDKSAyMDA2IGJ5IEx1Y2EgUmlzb2xpYSA8bHVjYS5yaXNvbGlhQHN0dWRpby51bmliby5pdD4gICAgICAgKgorICogQ29weXJpZ2h0IChDKSAyMDA2LTIwMDcgYnkgTHVjYSBSaXNvbGlhIDxsdWNhLnJpc29saWFAc3R1ZGlvLnVuaWJvLml0PiAgKgogICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgogICogSW5pdGlhbGl6YXRpb24gdmFsdWVzIG9mIHRoZSBaQzAzMDFbUF0gaGF2ZSBiZWVuIHRha2VuIGZyb20gdGhlIFNQQ0E1WFggKgogICogZHJpdmVyIG1haW50YWluZWQgYnkgTWljaGVsIFhoYWFyZCA8bXhoYWFyZEBtYWdpYy5mcj4gICAgICAgICAgICAgICAgICAgKgpkaWZmIC0tZ2l0IGEvZHJpdmVycy9tZWRpYS92aWRlby96YzAzMDEvemMwMzAxX3BiMDMzMC5jIGIvZHJpdmVycy9tZWRpYS92aWRlby96YzAzMDEvemMwMzAxX3BiMDMzMC5jCmluZGV4IGVkODU0MmUuLjU3ODRiMWQgMTAwNjQ0Ci0tLSBhL2RyaXZlcnMvbWVkaWEvdmlkZW8vemMwMzAxL3pjMDMwMV9wYjAzMzAuYworKysgYi9kcml2ZXJzL21lZGlhL3ZpZGVvL3pjMDMwMS96YzAzMDFfcGIwMzMwLmMKQEAgLTEsOCArMSw4IEBACiAvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqCi0gKiBQbHVnLWluIGZvciBQQi0wMzMwIGltYWdlIHNlbnNvciBjb25uZWN0ZWQgdG8gdGhlIFpDMDMwMVtQXSBJbWFnZSAgICAgICAqCisgKiBQbHVnLWluIGZvciBQQi0wMzMwIGltYWdlIHNlbnNvciBjb25uZWN0ZWQgdG8gdGhlIFpDMDMwMVAgSW1hZ2UgICAgICAgICAqCiAgKiBQcm9jZXNzb3IgYW5kIENvbnRyb2wgQ2hpcCAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCiAgKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCi0gKiBDb3B5cmlnaHQgKEMpIDIwMDYgYnkgTHVjYSBSaXNvbGlhIDxsdWNhLnJpc29saWFAc3R1ZGlvLnVuaWJvLml0PiAgICAgICAqCisgKiBDb3B5cmlnaHQgKEMpIDIwMDYtMjAwNyBieSBMdWNhIFJpc29saWEgPGx1Y2Eucmlzb2xpYUBzdHVkaW8udW5pYm8uaXQ+ICAqCiAgKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqCiAgKiBJbml0aWFsaXphdGlvbiB2YWx1ZXMgb2YgdGhlIFpDMDMwMVtQXSBoYXZlIGJlZW4gdGFrZW4gZnJvbSB0aGUgU1BDQTVYWCAqCiAgKiBkcml2ZXIgbWFpbnRhaW5lZCBieSBNaWNoZWwgWGhhYXJkIDxteGhhYXJkQG1hZ2ljLmZyPiAgICAgICAgICAgICAgICAgICAqCmRpZmYgLS1naXQgYS9kcml2ZXJzL21lZGlhL3ZpZGVvL3pjMDMwMS96YzAzMDFfc2Vuc29yLmggYi9kcml2ZXJzL21lZGlhL3ZpZGVvL3pjMDMwMS96YzAzMDFfc2Vuc29yLmgKaW5kZXggM2RhZjA0OS4uNDRlODJjZiAxMDA2NDQKLS0tIGEvZHJpdmVycy9tZWRpYS92aWRlby96YzAzMDEvemMwMzAxX3NlbnNvci5oCisrKyBiL2RyaXZlcnMvbWVkaWEvdmlkZW8vemMwMzAxL3pjMDMwMV9zZW5zb3IuaApAQCAtMSw4ICsxLDggQEAKIC8qKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioKLSAqIEFQSSBmb3IgaW1hZ2Ugc2Vuc29ycyBjb25uZWN0ZWQgdG8gdGhlIFpDMDMwMSBJbWFnZSBQcm9jZXNzb3IgYW5kICAgICAgICoKKyAqIEFQSSBmb3IgaW1hZ2Ugc2Vuc29ycyBjb25uZWN0ZWQgdG8gdGhlIFpDMDMwMVtQXSBJbWFnZSBQcm9jZXNzb3IgYW5kICAgICoKICAqIENvbnRyb2wgQ2hpcCAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICoKICAqICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICoKLSAqIENvcHlyaWdodCAoQykgMjAwNiBieSBMdWNhIFJpc29saWEgPGx1Y2Eucmlzb2xpYUBzdHVkaW8udW5pYm8uaXQ+ICAgICAgICoKKyAqIENvcHlyaWdodCAoQykgMjAwNi0yMDA3IGJ5IEx1Y2EgUmlzb2xpYSA8bHVjYS5yaXNvbGlhQHN0dWRpby51bmliby5pdD4gICoKICAqICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICoKICAqIF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b3JhdGlvbi4KKyAqICBDb3B5cmlnaHQgKGMpIDIwMDAtMjAwNiBMU0kgTG9naWMgQ29ycG9yYXRpb24uCiAgKgogICoKICAqICAgICAgICAgICBOYW1lOiAgbXBpX2NuZmcuaAogICogICAgICAgICAgVGl0bGU6ICBNUEkgQ29uZmlnIG1lc3NhZ2UsIHN0cnVjdHVyZXMsIGFuZCBQYWdlcwogICogIENyZWF0aW9uIERhdGU6ICBKdWx5IDI3LCAyMDAwCiAgKgotICogICAgbXBpX2NuZmcuaCBWZXJzaW9uOiAgMDEuMDUuMTIKKyAqICAgIG1waV9jbmZnLmggVmVyc2lvbjogIDAxLjA1LjEzCiAgKgogICogIFZlcnNpb24gSGlzdG9yeQogICogIC0tLS0tLS0tLS0tLS0tLQpAQCAtMjc2LDYgKzI3NiwyMyBAQAogICogICAgICAgICAgICAgICAgICAgICAgQWRkZWQgQWRkaXRpb25hbENvbnRyb2xGbGFncywgTWF4VGFyZ2V0UG9ydENvbm5lY3RUaW1lLAogICogICAgICAgICAgICAgICAgICAgICAgUmVwb3J0RGV2aWNlTWlzc2luZ0RlbGF5LCBhbmQgSU9EZXZpY2VNaXNzaW5nRGVsYXkKICAqICAgICAgICAgICAgICAgICAgICAgIGZpZWxkcyB0byBTQVMgSU8gVW5pdCBQYWdlIDEuCisgKiAgMTAtMTEtMDYgIDAxLjA1LjEzICBBZGRlZCBOdW1Gb3JjZVdXSUQgZmllbGQgYW5kIEZvcmNlV1dJRCBhcnJheSB0bworICogICAgICAgICAgICAgICAgICAgICAgTWFudWZhY3R1cmluZyBQYWdlIDUuCisgKiAgICAgICAgICAgICAgICAgICAgICBBZGRlZCBNYW51ZmFjdHVyaW5nIHBhZ2VzIDggdGhyb3VnaCAxMC4KKyAqICAgICAgICAgICAgICAgICAgICAgIEFkZGVkIGRlZmluZXMgZm9yIHN1cHBvcnRlZCBtZXRhZGF0YSBzaXplIGJpdHMgaW4KKyAqICAgICAgICAgICAgICAgICAgICAgIENhcGFiaWxpdGllc0ZsYWdzIGZpZWxkIG9mIElPQyBQYWdlIDYuCisgKiAgICAgICAgICAgICAgICAgICAgICBBZGRlZCBkZWZpbmVzIGZvciBtZXRhZGF0YSBzaXplIGJpdHMgaW4gVm9sdW1lU2V0dGluZ3MKKyAqICAgICAgICAgICAgICAgICAgICAgIGZpZWxkIG9mIFJBSUQgVm9sdW1lIFBhZ2UgMC4KKyAqICAgICAgICAgICAgICAgICAgICAgIEFkZGVkIFNBVEEgTGluayBSZXNldCBzZXR0aW5ncywgRW5hYmxlIFNBVEEgQXN5bmNocm9ub3VzCisgKiAgICAgICAgICAgICAgICAgICAgICBOb3RpZmljYXRpb24gYml0LCBhbmQgSGlkZU5vblplcm9BdHRhY2hlZFBoeUlkZW50aWZpZXJzCisgKiAgICAgICAgICAgICAgICAgICAgICBiaXQgdG8gQWRkaXRpb25hbENvbnRyb2xGbGFncyBmaWVsZCBvZiBTQVMgSU8gVW5pdAorICogICAgICAgICAgICAgICAgICAgICAgUGFnZSAxLgorICogICAgICAgICAgICAgICAgICAgICAgQWRkZWQgZGVmaW5lcyBmb3IgRW5jbG9zdXJlIERldmljZXMgVW5tYXBwZWQgYW5kCisgKiAgICAgICAgICAgICAgICAgICAgICBEZXZpY2UgTGltaXQgRXhjZWVkZWQgYml0cyBpbiBTdGF0dXMgZmllbGQgb2YgU0FTIElPCisgKiAgICAgICAgICAgICAgICAgICAgICBVbml0IFBhZ2UgMi4KKyAqICAgICAgICAgICAgICAgICAgICAgIEFkZGVkIG1vcmUgQWNjZXNzU3RhdHVzIHZhbHVlcyBmb3IgU0FTIERldmljZSBQYWdlIDAuCisgKiAgICAgICAgICAgICAgICAgICAgICBBZGRlZCBiaXQgZm9yIFNBVEEgQXN5bmNocm9ub3VzIE5vdGlmaWNhdGlvbiBTdXBwb3J0IGluCisgKiAgICAgICAgICAgICAgICAgICAgICBGbGFncyBmaWVsZCBvZiBTQVMgRGV2aWNlIFBhZ2UgMC4KICAqICAtLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLQogICovCiAKQEAgLTY1NCwxNyArNjcxLDI0IEBACiAjZGVmaW5lIE1QSV9NQU5QQUdFNF9JUl9OT19NSVhfU0FTX1NBVEEgICAgICAgICAgICAgICAgICgweDAxKQogCiAKKyNpZm5kZWYgTVBJX01BTlBBR0U1X05VTV9GT1JDRVdXSUQKKyNkZWZpbmUgTVBJX01BTlBBR0U1X05VTV9GT1JDRVdXSUQgICAgICAoMSkKKyNlbmRpZgorCiB0eXBlZGVmIHN0cnVjdCBfQ09ORklHX1BBR0VfTUFOVUZBQ1RVUklOR181CiB7CiAgICAgQ09ORklHX1BBR0VfSEVBREVSICAgICAgICAgICAgICBIZWFkZXI7ICAgICAgICAgICAgIC8qIDAwaCAqLwogICAgIFU2NCAgICAgICAgICAgICAgICAgICAgICAgICAgICAgQmFzZVdXSUQ7ICAgICAgICAgICAvKiAwNGggKi8KICAgICBVOCAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIEZsYWdzOyAgICAgICAgICAgICAgLyogMENoICovCi0gICAgVTggICAgICAgICAgICAgICAgICAgICAgICAgICAgICBSZXNlcnZlZDE7ICAgICAgICAgIC8qIDBEaCAqLworICAgIFU4ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgTnVtRm9yY2VXV0lEOyAgICAgICAvKiAwRGggKi8KICAgICBVMTYgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFJlc2VydmVkMjsgICAgICAgICAgLyogMEVoICovCisgICAgVTMyICAgICAgICAgICAgICAgICAgICAgICAgICAgICBSZXNlcnZlZDM7ICAgICAgICAgIC8qIDEwaCAqLworICAgIFUzMiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgUmVzZXJ2ZWQ0OyAgICAgICAgICAvKiAxNGggKi8KKyAgICBVNjQgICAgICAgICAgICAgICAgICAgICAgICAgICAgIEZvcmNlV1dJRFtN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pbmUgTVBJX01BTlVGQUNUVVJJTkc4X1BBR0VWRVJTSU9OICAgICAgICAgICAgICAgICAgKDB4MDApCisKKwordHlwZWRlZiBzdHJ1Y3QgX0NPTkZJR19QQUdFX01BTlVGQUNUVVJJTkdfOQoreworICAgIENPTkZJR19QQUdFX0hFQURFUiAgICAgICAgICAgICAgSGVhZGVyOyAgICAgICAgICAgICAvKiAwMGggKi8KKyAgICBVMzIgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFByb2R1Y3RTcGVjaWZpY0luZm87LyogMDRoICovCit9IENPTkZJR19QQUdFX01BTlVGQUNUVVJJTkdfOSwgTVBJX1BPSU5URVIgUFRSX0NPTkZJR19QQUdFX01BTlVGQUNUVVJJTkdfOSwKKyAgTWFudWZhY3R1cmluZ1BhZ2U5X3QsIE1QSV9QT0lOVEVSIHBNYW51ZmFjdHVyaW5nUGFnZTlfdDsKKworI2RlZmluZSBNUElfTUFOVUZBQ1RVUklORzZfUEFHRVZFUlNJT04gICAgICAgICAgICAgICAgICAoMHgwMCkKKworCit0eXBlZGVmIHN0cnVjdCBfQ09ORklHX1BBR0VfTUFOVUZBQ1RVUklOR18xMAoreworICAgIENPTkZJR19QQUdFX0hFQURFUiAgICAgICAgICAgICAgSGVhZGVyOyAgICAgICAgICAgICAvKiAwMGggKi8KKyAgICBVMzIgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFByb2R1Y3RTcGVjaWZpY0luZm87LyogMDRoICovCit9IENPTkZJR19QQUdFX01BTlVGQUNUVVJJTkdfMTAsIE1QSV9QT0lOVEVSIFBUUl9DT05GSUdfUEFHRV9NQU5VRkFDVFVSSU5HXzEwLAorICBNYW51ZmFjdHVyaW5nUGFnZTEwX3QsIE1QSV9QT0lOVEVSIHBNYW51ZmFjdHVyaW5nUGFnZTEwX3Q7CisKKyNkZWZpbmUgTVBJX01BTlVGQUNUVVJJTkcxMF9QQUdFVkVSU0lPTiAgICAgICAgICAgICAgICAgKDB4MDApCisKKwogLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioKICogICBJTyBVbml0IENvbmZpZyBQYWdlcwogKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKi8KQEAgLTEwODAsMTAgKzExMzQsMTQgQEAKIH0gQ09ORklHX1BBR0VfSU9DXzYsIE1QSV9QT0lOVEVSIFBUUl9DT05GSUdfUEFHRV9JT0NfNiwKICAgSU9DUGFnZTZfdCwgTVBJX1BPSU5URVIgcElPQ1BhZ2U2X3Q7CiAKLSNkZWZpbmUgTVBJX0lPQ1BBR0U2X1BBR0VWRVJTSU9OICAgICAgICAgICAgICAgICAgICAgICAgKDB4MDApCisjZGVmaW5lIE1QSV9JT0NQQUdFNl9QQUdFVkVSU0lPTiAgICAgICAgICAgICAgICAgICAgICAgICgweDAxKQogCiAvKiBJT0MgUGFnZSA2IENhcGFiaWxpdGllcyBGbGFncyAqLwogCisjZGVmaW5lIE1QSV9JT0NQQUdFNl9DQVBfRkxBR1NfTUFTS19NRVRBREFUQV9TSVpFICAgICAgICgweDAwMDAwMDA2KQorI2RlZmluZSBNUElfSU9DUEFHRTZfQ0FQX0ZMQUdTXzY0TUJfTUVUQURBVEFfU0laRSAgICAgICAoMHgwMDAwMDAwMCkKKyNkZWZpbmUgTVBJX0lPQ1BBR0U2X0NBUF9GTEFHU181MTJNQl9NRVRBREFUQV9TSVpFICAgICAgKDB4MDAwMDAwMDIpCisKICNkZWZpbmUgTVBJX0lPQ1BBR0U2X0NBUF9GTEFHU19HTE9CQUxfSE9UX1NQQVJFICAgICAgICAgKDB4MDAwMDAwMDEpCiAKIApAQCAtMjE2MCw2ICsyMjE4LDExIEBACiAjZGVmaW5lIE1QSV9SQUlEVk9MMF9TRVRUSU5HX0FVVE9fQ09ORklHVVJFICAgICAgICAgICAgICgweDAwMDQpCiAjZGVmaW5lIE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tLS0tLSAgICAgICAgICAgICAtLS0tLS0tLS0tLS0tLS0gICAgIC0tLS0tLS0tLS0tLS0KLSBtcGkuaCAgICAgICAgICAgICAgICAgIDAxLjA1LjExICAgICAgICAgICAgMDEuMDUuMTAKLSBtcGlfaW9jLmggICAgICAgICAgICAgIDAxLjA1LjExICAgICAgICAgICAgMDEuMDUuMTAKLSBtcGlfY25mZy5oICAgICAgICAgICAgIDAxLjA1LjEyICAgICAgICAgICAgMDEuMDUuMTEKLSBtcGlfaW5pdC5oICAgICAgICAgICAgIDAxLjA1LjA3ICAgICAgICAgICAgMDEuMDUuMDYKLSBtcGlfdGFyZy5oICAgICAgICAgICAgIDAxLjA1LjA2ICAgICAgICAgICAgMDEuMDUuMDUKKyBtcGkuaCAgICAgICAgICAgICAgICAgIDAxLjA1LjEyICAgICAgICAgICAgMDEuMDUuMTEKKyBtcGlfaW9jLmggICAgICAgICAgICAgIDAxLjA1LjEyICAgICAgICAgICAgMDEuMDUuMTEKKyBtcGlfY25mZy5oICAgICAgICAgICAgIDAxLjA1LjEzICAgICAgICAgICAgMDEuMDUuMTIKKyBtcGlfaW5pdC5oICAgICAgICAgICAgIDAxLjA1LjA4ICAgICAgICAgICAgMDEuMDUuMDcKKyBtcGlfdGFyZy5oICAgICAgICAgICAgIDAxLjA1LjA2ICAgICAgICAgICAgMDEuMDUuMDYKICBtcGlfZmMuaCAgICAgICAgICAgICAgIDAxLjA1LjAxICAgICAgICAgICAgMDEuMDUuMDEKICBtcGlfbGFuLmggICAgICAgICAgICAgIDAxLjA1LjAxICAgICAgICAgICAgMDEuMDUuMDEKICBtcGlfcmFpZC5oICAgICAgICAgICAgIDAxLjA1LjAyICAgICAgICAgICAgMDEuMDUuMDIKICBtcGlfdG9vbC5oICAgICAgICAgICAgIDAxLjA1LjAzICAgICAgICAgICAgMDEuMDUuMDMKICBtcGlfaW5iLmggICAgICAgICAgICAgIDAxLjA1LjAxICAgICAgICAgICAgMDEuMDUuMDEKLSBtcGlfc2F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FlQRV9JTklUSUFMSVpBVElPTi4KKyAqICAxMC0xMS0wNiAgMDEuMDUuMTIgIEFkZGVkIE1QSV9JT0NGQUNUU19FWENFUFRfTUVUQURBVEFfVU5TVVBQT1JURUQuCisgKiAgICAgICAgICAgICAgICAgICAgICBBZGRlZCBNYXhJbml0aWF0b3JzIGZpZWxkIHRvIFBvcnRGYWN0cyByZXBseS4KKyAqICAgICAgICAgICAgICAgICAgICAgIEFkZGVkIFNBUyBEZXZpY2UgU3RhdHVzIENoYW5nZSBSZWFzb25Db2RlIGZvcgorICogICAgICAgICAgICAgICAgICAgICAgYXN5bmNocm9ub3VzIG5vdGlmaWNhaXRvbi4KKyAqICAgICAgICAgICAgICAgICAgICAgIEFkZGVkIE1QSV9FVkVOVF9TQVNfRVhQQU5ERVJfU1RBVFVTX0NIQU5HRSBhbmQgZXZlbnQKKyAqICAgICAgICAgICAgICAgICAgICAgIGRhdGEgc3RydWN0dXJlLgorICogICAgICAgICAgICAgICAgICAgICAgQWRkZWQgbmV3IEltYWdlVHlwZSB2YWx1ZXMgZm9yIEZXRG93bmxvYWQgYW5kIEZXVXBsb2FkCisgKiAgICAgICAgICAgICAgICAgICAgICByZXF1ZXN0cy4KICAqICAtLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLQogCiBtcGlfY25mZy5oCkBAIC00NDcsNiArNDU2LDIzIEBACiAgKiAgICAgICAgICAgICAgICAgICAgICBBZGRlZCBBZGRpdGlvbmFsQ29udHJvbEZsYWdzLCBNYXhUYXJnZXRQb3J0Q29ubmVjdFRpbWUsCiAgKiAgICAgICAgICAgICAgICAgICAgICBSZXBvcnREZXZpY2VNaXNzaW5nRGVsYXksIGFuZCBJT0RldmljZU1pc3NpbmdEZWxheQogICogICAgICAgICAgICAgICAgICAgICAgZmllbGRzIHRvIFNBUyBJTyBVbml0IFBhZ2UgMS4KKyAqICAxMC0xMS0wNiAgMDEuMDUuMTMgIEFkZGVkIE51bUZvcmNlV1dJRCBmaWVsZCBhbmQgRm9yY2VXV0lEIGFycmF5IHRvCisgKiAgICAgICAgICAgICAgICAgICAgICBNYW51ZmFjdHVyaW5nIFBhZ2UgNS4KKyAqICAgICAgICAgICAgICAgICAgICAgIEFkZGVkIE1hbnVmYWN0dXJpbmcgcGFnZXMgOCB0aHJvdWdoIDEwLgorICogICAgICAgICAgICAgICAgICAgICAgQWRkZWQgZGVmaW5lcyBmb3Igc3VwcG9ydGVkIG1ldGFkYXRhIHNpemUgYml0cyBpbgorICogICAgICAgICAgICAgICAgICAgICAgQ2FwYWJpbGl0aWVzRmxhZ3MgZmllbGQgb2YgSU9DIFBhZ2UgNi4KKyAqICAgICAgICAgICAgICAgICAgICAgIEFkZGVkIGRlZmluZXMgZm9yIG1ldGFkYXRhIHNpemUgYml0cyBpbiBWb2x1bWVTZXR0aW5ncworICogICAgICAgICAgICAgICAgICAgICAgZmllbGQgb2YgUkFJRCBWb2x1bWUgUGFnZSAwLgorICogICAgICAgICAgICAgICAgICAgICAgQWRkZWQgU0FUQSBMaW5rIFJlc2V0IHNldHRpbmdzLCBFbmFibGUgU0FUQSBBc3luY2hyb25vdXMKKyAqICAgICAgICAgICAgICAgICAgICAgIE5vdGlmaWNhdGlvbiBiaXQsIGFuZCBIaWRlTm9uWmVyb0F0dGFjaGVkUGh5SWRlbnRpZmllcnMKKyAqICAgICAgICAgICAgICAgICAgICAgIGJpdCB0byBBZGRpdGlvbmFsQ29udHJvbEZsYWdzIGZpZWxkIG9mIFNBUyBJTyBVbml0CisgKiAgICAgICAgICAgICAgICAgICAgICBQYWdlIDEuCisgKiAgICAgICAgICAgICAgICAgICAgICBBZGRlZCBkZWZpbmVzIGZvciBFbmNsb3N1cmUgRGV2aWNlcyBVbm1hcHBlZCBhbmQKKyAqICAgICAgICAgICAgICAgICAgICAgIERldmljZSBMaW1pdCBFeGNlZWRlZCBiaXRzIGluIF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jZGVmaW5lIE1QSV9JT0NGQUNUU19GTEFHU19SRVBMWV9GSUZPX0hPU1RfU0lHTkFMICAgICAgICgweDAyKQpAQCAtMzI4LDcgKzMzNyw4IEBACiAgICAgIFUxNiAgICAgICAgICAgICAgICAgICAgTWF4UG9zdGVkQ21kQnVmZmVyczsgICAgICAgIC8qIDFDaCAqLwogICAgICBVMTYgICAgICAgICAgICAgICAgICAgIE1heFBlcnNpc3RlbnRJRHM7ICAgICAgICAgICAvKiAxRWggKi8KICAgICAgVTE2ICAgICAgICAgICAgICAgICAgICBNYXhMYW5CdWNrZXRzOyAgICAgICAgICAgICAgLyogMjBoICovCi0gICAgIFUxNiAgICAgICAgICAgICAgICAgICAgUmVzZXJ2ZWQ0OyAgICAgICAgICAgICAgICAgIC8qIDIyaCAqLworICAgICBVOCAgICAgICAgICAgICAgICAgICAgIE1heEluaXRpYXRvcnM7ICAgICAgICAgICAgICAvKiAyMmggKi8KKyAgICAgVTggICAgICAgICAgICAgICAgICAgICBSZXNlcnZlZDQ7ICAgICAgICAgICAgICAgICAgLyogMjNoICovCiAgICAgIFUzMiAgICAgICAgICAgICAgICAgICAgUmVzZXJ2ZWQ1OyAgICAgICAgICAgICAgICAgIC8qIDI0aCAqLwogfSBNU0dfUE9SVF9GQUNUU19SRVBMWSwgTVBJX1BPSU5URVIgUFRSX01TR19QT1JUX0ZBQ1RTX1JFUExZLAogICBQb3J0RmFjdHNSZXBseV90LCBNUElfUE9JTlRFUiBwUG9ydEZhY3RzUmVwbHlfdDsKQEAgLTQ4Nyw2ICs0OTcsNyBAQAogI2RlZmluZSBNUElfRVZFTlRfU0FTX0lOSVRfREVWSUNFX1NUQVRVU19DSEFOR0UgKDB4MDAwMDAwMTgpCiAjZGVmaW5lIE1QSV9FVkVOVF9TQVNfSU5JVF9UQUJMRV9PVkVSRkxPVyAgICAgICAoMHgwMDAwMDAxOSkKICNkZWZpbmUgTVBJX0VWRU5UX1NBU19TTVBfRVJST1IgICAgICAgICAgICAgIC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sgICAgICAgICAgICAgIC8qIDAxaCAqLworICAgIFUxNiAgICAgICAgICAgICAgICAgICAgIFJlc2VydmVkMjsgICAgICAgICAgICAgIC8qIDAyaCAqLworICAgIFU4ICAgICAgICAgICAgICAgICAgICAgIFBoeXNpY2FsUG9ydDsgICAgICAgICAgIC8qIDA0aCAqLworICAgIFU4ICAgICAgICAgICAgICAgICAgICAgIFJlc2VydmVkMzsgICAgICAgICAgICAgIC8qIDA1aCAqLworICAgIFUxNiAgICAgICAgICAgICAgICAgICAgIEVuY2xvc3VyZUhhbmRsZTsgICAgICAgIC8qIDA2aCAqLworICAgIFU2NCAgICAgICAgICAgICAgICAgICAgIFNBU0FkZHJlc3M7ICAgICAgICAgICAgIC8qIDA4aCAqLworICAgIFUzMiAgICAgICAgICAgICAgICAgICAgIERpc2NvdmVyeVN0YXR1czsgICAgICAgIC8qIDEwaCAqLworICAgIFUxNiAgICAgICAgICAgICAgICAgICAgIERldkhhbmRsZTsgICAgICAgICAgICAgIC8qIDE0aCAqLworICAgIFUxNiAgICAgICAgICAgICAgICAgICAgIFBhcmVudERldkhhbmRsZTsgICAgICAgIC8qIDE2aCAqLworICAgIFUxNiAgICAgICAgICAgICAgICAgICAgIEV4cGFuZGVyQ2hhbmdlQ291bnQ7ICAgIC8qIDE4aCAqLworICAgIFUxNiAgICAgICAgICAgICAgICAgICAgIEV4cGFuZGVyUm91dGVJbmRleGVzOyAgIC8qIDFBaCAqLworICAgIFU4ICAgICAgICAgICAgICAgICAgICAgIE51bVBoeXM7ICAgICAgICAgICAgICAgIC8qIDFDaCAqLworICAgIFU4ICAgICAgICAgICAgICAgICAgICAgIFNBU0xldmVsOyAgICAgICAgICAgICAgIC8qIDFEaCAqLworICAgIFU4ICAgICAgICAgICAgICAgICAgICAgIEZsYWdzOyAgICAgICAgICAgICAgICAgIC8qIDFFaCAqLworICAgIFU4ICAgICAgICAgICAgICAgICAgICAgIFJlc2VydmVkNDsgICAgICAgICAgICAgIC8qIDFGaCAqLwor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9JVFlQRV9CSU9TICAgICAgICAgICAgICAoMHgwMikKICNkZWZpbmUgTVBJX0ZXX0RPV05MT0FEX0lUWVBFX05WREFUQSAgICAgICAgICAgICgweDAzKQogI2RlZmluZSBNUElfRldfRE9XTkxPQURfSVRZUEVfQk9PVExPQURFUiAgICAgICAgKDB4MDQpCisjZGVmaW5lIE1QSV9GV19ET1dOTE9BRF9JVFlQRV9NQU5VRkFDVFVSSU5HICAgICAoMHgwNikKKyNkZWZpbmUgTVBJX0ZXX0RPV05MT0FEX0lUWVBFX0NPTkZJR18xICAgICAgICAgICgweDA3KQorI2RlZmluZSBNUElfRldfRE9XTkxPQURfSVRZUEVfQ09ORklHXzIgICAgICAgICAgKDB4MDgpCisjZGVmaW5lIE1QSV9GV19ET1dOTE9BRF9JVFlQRV9NRUdBUkFJRCAgICAgICAgICAoMHgwOSkKIAogCiB0eXBlZGVmIHN0cnVjdCBfRldEb3dubG9hZFRDU0dFCkBAIC05ODAsNiArMTA0NCwxMSBAQAogI2RlZmluZSBNUElfRldfVVBMT0FEX0lUWVBFX05WREFUQSAgICAgICAgICAoMHgwMykKICNkZWZpbmUgTVBJX0ZXX1VQTE9BRF9JVFlQRV9CT09UTE9BREVSICAgICAgKDB4MDQpCiAjZGVmaW5lIE1QSV9GV19VUExPQURfSVRZUEVfRldfQkFDS1VQICAgICAgICgweDA1KQorI2RlZmluZSBNUElfRldfVVBMT0FEX0lUWVBFX01BTlVGQUNUVVJJTkcgICAoMHgwNikKKyNkZWZpbmUgTVBJX0ZXX1VQTE9BRF9JVFlQRV9DT05GSUdfMSAgICAgICAgKDB4MDcpCisjZGVmaW5lIE1QSV9GV19VUExPQURfSVRZUEVfQ09ORklHXzIgICAgICAgICgweDA4KQorI2RlZmluZSBNUElfRldfVVBMT0FEX0lUWVBFX01FR0FSQUlEICAgICAgICAoMHgwOSkKKyNkZWZpbmUgTVBJX0ZXX1VQTE9BRF9JVFlQRV9DT01QTEVURSAgICAgICAgKDB4MEEpCiAKIHR5cGVkZWYgc3RydWN0IF9GV1VwbG9hZFRDU0dFCiB7CmRpZmYgLS1naXQgYS9kcml2ZXJzL21lc3NhZ2UvZnVzaW9uL2xzaS9tcGlfbG9nX3Nhcy5oIGIvZHJpdmVycy9tZXNzYWdlL2Z1c2lvbi9sc2kvbXBpX2xvZ19zYXMuaAppbmRleCA4NzFlYmMwLi42MzViYmUwIDEwMDY0NAotLS0gYS9kcml2ZXJzL21lc3NhZ2UvZnVzaW9uL2xzaS9tcGlfbG9nX3Nhcy5oCisrKyBiL2RyaXZlcnMvbWVzc2FnZS9mdXNpb24vbHNpL21waV9sb2dfc2FzLmgKQEAgLTEsNCArMSwzIEBACi0KIC8qKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioKICAqICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICoKICAqICBDb3B5cmlnaHQgMjAwMyBMU0kgTG9naWMgQ29ycG9yYXRpb24uICBBbGwgcmlnaHRzIHJlc2VydmVkLiAgICAgICAgICAgICoKQEAgLTE0LDcgKzEzLDcgQEAKICNkZWZpbmUgSU9QSV9JT0NMT0dJTkZPX0hfSU5DTFVERUQKIAogI2RlZmluZSBTQVNfTE9HSU5GT19ORVhVU19MT1NTCQkweDMxMTcwMDAwCi0jZGVmaW5lIFNBU19MT0dJTkZPX01BU0sJCQkweEZGRkYwMDAwCisjZGVmaW5lIFNBU19MT0dJTkZPX01BU0sJCTB4RkZGRjAwMDAKIAogLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiovCiAvKiAgSU9DIExPR0lORk8gZGVmaW5lcywgMHgwMDAwMDAwMCAtIDB4MEZGRkZGRkYgICAgICAgICAgICAgICAgICAgICAgICAgICAgKi8KQEAgLTQzLDEyOSArNDIsMTcyIEBACiAvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKi8KIC8qIElPUCBMT0dJTkZPX0NPREUgZGVmaW5lcywgdmFsaWQgaWYgSU9DX0xPR0lORk9fT1JJR0lOQVRPUiA9IElPUCAgICAgICAgICAqLwogLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiovCi0jZGVmaW5lIElPUF9MT0dJTkZPX0NPREVfSU5WQUxJRF9TQVNfQUREUkVTUyAgICAgICAgICAgICgweDAwMDEwMDAwKQotI2RlZmluZSBJT1BfTE9HSU5GT19DT0RFX1VOVVNFRDIgICAgICAgICAgICAgICAgICAgICAgICAoMHgwMDAyMDAwMCkKLSNkZWZpbmUgSU9QX0xPR0lORk9fQ09ERV9DT05GSUdfSU5WQUxJRF9QQUdFICAgICAgICAgICAgKDB4MDAwMzAwMDApCi0jZGVmaW5lIElPUF9MT0dJTkZPX0NPREVfQ09ORklHX0lOVkFMSURfUEFHRV9SVCAgICAgICAgICgweDAwMDMwMTAwKSAvKiBSb3V0ZSBUYWJsZSBFbnRyeSBub3QgZm91bmQgKi8KLSNkZWZpbmUgSU9QX0xPR0lORk9fQ09ERV9DT05GSUdfSU5WQUxJRF9QQUdFX1BOICAgICAgICAgKDB4MDAwMzAyMDApIC8qIEludmFsaWQgUGFnZSBOdW1iZXIgKi8KLSNkZWZpbmUgSU9QX0xPR0lORk9fQ09ERV9DT05GSUdfSU5WQUxJRF9QQUdFX0ZPUk0gICAgICAgKDB4MDAwMzAzMDApIC8qIEludmFsaWQgRk9STSAqLwotI2RlZmluZSBJT1BfTE9HSU5GT19DT0RFX0NPTkZJR19JTlZBTElEX1BBR0VfUFQgICAgICAgICAoMHgwMDAzMDQwMCkgLyogSW52YWxpZCBQYWdlIFR5cGUgKi8KLSNkZWZpbmUgSU9QX0xPR0lORk9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EFUVVNfU0VORF9URVJNSU5BVEVEICAgICAgICgweDAwMDcwMDAyKQorI2RlZmluZSBJT1BfTE9HSU5GT19DT0RFX1RBUkdFVF9NT0RFX0FCT1JUX0FMTF9JTyAgICAgICAgICAgICgweDAwMDcwMDAzKQorI2RlZmluZSBJT1BfTE9HSU5GT19DT0RFX1RBUkdFVF9NT0RFX0FCT1JUX0VYQUNUX0lPICAgICAgICAgICgweDAwMDcwMDA0KQorI2RlZmluZSBJT1BfTE9HSU5GT19DT0RFX1RBUkdFVF9NT0RFX0FCT1JUX0VYQUNUX0lPX1JFUSAgICAgICgweDAwMDcwMDA1KQogCiAvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKi8KIC8qIFBMIExPR0lORk9fQ09ERSBkZWZpbmVzLCB2YWxpZCBpZiBJT0NfTE9HSU5GT19PUklHSU5BVE9SID0gUEwgICAgICAgICAgICAqLwogLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiovCi0jZGVmaW5lIFBMX0xPR0lORk9fQ09ERV9PUEVOX0ZBSUxVUkUgICAgICAgICAgICAgICAgICAgICAgICAoMHgwMDAxMDAwMCkKLSNkZWZpbmUgUExfTE9HX0lORk9fQ09ERV9PUEVOX0ZBSUxVUkVfTk9fREVTVF9USU1FX09VVCAgICAgICgweDAwMDEwMDAxKQotI2RlZmluZSBQTF9MT0dJTkZPX0NPREVfT1BFTl9GQUlMVVJFX0JBRF9ERVNUSU5BVElPTiAgICAgICAgKDB4MDAwMTAwMTEpCi0jZGVmaW5lIFBMX0xPR0lORk9fQ09ERV9PUEVOX0ZBSUxVUkVfUFJPVE9DT0xfTk9UX1NVUFBPUlRFRCAoMHgwMDAxMDAxMykKLSNkZWZpbmUgUExfTE9HSU5GT19DT0RFX09QRU5fRkFJTFVSRV9TVFBfUkVTT1VSQ0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Tk9fREVWICAgICAgICAgICAoMHgwMDBGMDQwMCkgLyogTm8gRGV2aWNlIEZvdW5kICovCisjZGVmaW5lIFBMX0xPR0lORk9fQ09ERV9DT05GSUdfSU5WQUxJRF9QQUdFX0ZPUk0gICAgICAgICAgICAgKDB4MDAwRjA1MDApIC8qIEludmFsaWQgRk9STSAqLworI2RlZmluZSBQTF9MT0dJTkZPX0NPREVfQ09ORklHX0lOVkFMSURfUEFHRV9QSFkgICAgICAgICAgICAgICgweDAwMEYwNjAwKSAvKiBJbnZhbGlkIFBoeSAqLworI2RlZmluZSBQTF9MT0dJTkZPX0NPREVfQ09ORklHX0lOVkFMSURfUEFHRV9OT19PV05FUiAgICAgICAgICgweDAwMEYwNzAwKSAvKiBObyBPd25lciBGb3VuZCAqLworI2RlZmluZSBQTF9MT0dJTkZPX0NPREVfRFNDVlJZX1NBVEFfSU5JVF9USU1FT1VUICAgICAgICAgICAgICgweDAwMTAwMDAwKQorI2RlZmluZSBQTF9MT0dJTkZPX0NPREVfUkVTRVQgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICgweDAwMTEwMDAwKSAvKiBTZWUgU3ViLUNvZGVzIGJlbG93IChQTF9MT0dJTkZPX1NVQl9DT0RFKSAqLworI2RlZmluZSBQTF9MT0dJTkZPX0NPREVfQUJPUlQgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICgweDAwMTIwMDAwKSAvKiBTZWUgU3ViLUNvZGVzIGJlbG93ICAoUExfTE9HSU5GT19TVUJfQ09ERSkqLworI2RlZmluZSBQTF9MT0dJTkZPX0NPREVfSU9fTk9UX1lFVF9FWEVDVVRFRCAgICAgICAgICAgICAgICAgICgweDAwMTMwMDAwKQorI2RlZmluZSBQTF9MT0dJTkZPX0NPREVfSU9fRVhFQ1VURUQgICAgICAgICAgICAgICAgICAgICAgICAgICgweDAwMTQwMDAwKQorI2RlZmluZSBQTF9MT0dJTkZPX0NPREVfUEVSU19SRVNWX09VVF9OT1RfQUZGSUxfT1dORV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V9MRU5HVEggICAgKDB4MDAwMDAzMDApCisjZGVmaW5lIFBMX0xPR0lORk9fU1VCX0NPREVfRlJBTUVfWEZFUl9FUlJPUiAgICAgICAgICAgICAgICAgKDB4MDAwMDA0MDApIC8qIEJpdHMgMC0zIGVuY29kZSBUcmFuc3BvcnQgU3RhdHVzIFJlZ2lzdGVyIChvZmZzZXQgMHgwOCkgKi8KKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLyogQml0IDAgaXMgU3RhdHVzIEJpdCAwOiBGcmFtZVhmZXJFcnIgKi8KKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLyogQml0IDEgJiAyIGFyZSBTdGF0dXMgQml0cyAxNiBhbmQgMTc6IEZyYW1lWG1pdEVyclN0YXR1cyAqLworICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAvKiBCaXQgMyBpcyBTdGF0dXMgQml0IDE4IFdyaXRlRGF0YUxlbmdodEdURGF0YUxlbmd0aEVyciAqLwogCi0jZGVmaW5lIFBMX0xPR0lORk9fREFfU0VQX05PVF9QUkVTRU5UICAgICAgICAgICAgICAgICAgICAgICAoMHgwMDIwMDEwMCkgLyogU0VQIG5vdCBwcmVzZW50IHdoZW4gbXNnIHJlY2VpdmVkICovCi0jZGVmaW5lIFBMX0xPR0lORk9fREFfU0VQX1NJTkdMRV9USFJFQURfRVJST1IgICAgICAgICAgICAgICAoMHgwMDIwMDEwMSkgLyogQ2FuIG9ubHkgYWNjZXB0IDEgbXNnIGF0IGEgdGltZSAqLwotI2RlZmluZSBQTF9MT0dJTkZPX0RBX1NFUF9JU1RXSV9JTlRSX0lOX0lETEVfU1RBVEUgICAgICAgICAgKDB4MDAyMDAxMDIpIC8qIElTVFdJIGludGVycnVw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worLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiovCisvKiAgQ29tbW9uIElPQ1N0YXR1cyB2YWx1ZXMgZm9yIGFsbCByZXBsaWVzICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKi8KKy8qKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqLworCiAJY2FzZSBNUElfSU9DU1RBVFVTX0lOVkFMSURfRlVOQ1RJT046IC8qIDB4MDAwMSAqLwogCQlkZXNjID0gIkludmFsaWQgRnVuY3Rpb24iOwogCQlicmVhazsKQEAgLTYzMjIsODQgKzY3OTAsMTgwIEBACiAJCWRlc2MgPSAiSW52YWxpZCBTdGF0ZSI7CiAJCWJyZWFrOwogCisvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKi8KKy8qICBDb25maWcgSU9DU3RhdHVzIHZhbHVlcyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqLworLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiovCisKIAljYXNlIE1QSV9JT0NTVEFUVVNfQ09ORklHX0lOVkFMSURfQUNUSU9OOiAvKiAweDAwMjAgKi8KIAljYXNlIE1QSV9JT0NTVEFUVVNfQ09ORklHX0lOVkFMSURfVFlQRTogICAvKiAweDAwMjEgKi8KIAljYXNlIE1QSV9JT0NTVEFUVVNfQ09ORklHX0lOVkFMSURfUEFHRTogICAvKiAweDAwMjIgKi8KIAljYXNlIE1QSV9JT0NTVEFUVVNfQ09ORklHX0lOVkFMSURfREFUQTogICAvKiAweDAwMjMgKi8KIAljYXNlIE1QSV9JT0NTVEFUVVNfQ09ORklHX05PX0RFRkFVTFRTOiAgICAvKiAweDAwMjQgKi8KIAljYXNlIE1QSV9JT0NTVEFUVVNfQ09ORklHX0NBTlRfQ09NTUlUOiAgICAvKiAweDAwMjUgKi8KLQkJLyogTm8gbWVzc2FnZSBmb3IgQ29uZmlnIElPQ1N0YXR1cyB2YWx1ZXMgKi8KKwkJbXB0X2lvY3N0YXR1c19pbmZvX2NvbmZpZyhpb2MsIHN0YXR1cywgbWYpOwogCQlicmVhazsKIAorLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiovCisvKiAgU0NTSUlPIFJlcGx5IChTUEksIEZDUCwgU0FTKSBpbml0aWF0b3IgdmFsdWVzICAgICAgICAgICAgICAgICAgICAgICAgICAgKi8KKy8qICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqLworLyogIExvb2sgYXQgbXB0c2NzaWhfaW9jc3RhdHVzX2luZm9fc2NzaWlvIGluIG1wdHNjc2loLmMgKi8KKy8qICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqLworLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiovCisKIAljYXNlIE1QSV9JT0NTVEFUVVNfU0NTSV9SRUNPVkVSRURfRVJST1I6IC8qIDB4MDA0MCAqLwotCQkvKiBObyBtZXNzYWdlIGZvciByZWNvdmVyZWQgZXJyb3IKLQkJZGVzYyA9ICJTQ1NJIFJlY292ZXJlZCBFcnJvciI7Ci0JCSovCi0JCWJyZWFrOwotCi0JY2FzZSBNUElfSU9DU1RBVFVTX1NDU0lfSU5WQUxJRF9CVVM6IC8qIDB4MDA0MSAqLwotCQlkZXNjID0gIlNDU0kgSW52YWxpZCBCdXMiOwot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JTQ1NJIEV4dCBUZXJtaW5hdGVkIjsKKy8qKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqLworLyogIFNDU0kgVGFyZ2V0IHZhbHVlcyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICovCisvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKi8KKworCWNhc2UgTVBJX0lPQ1NUQVRVU19UQVJHRVRfUFJJT1JJVFlfSU86IC8qIDB4MDA2MCAqLworCQlkZXNjID0gIlRhcmdldDogUHJpb3JpdHkgSU8iOworCQlicmVhazsKKworCWNhc2UgTVBJX0lPQ1NUQVRVU19UQVJHRVRfSU5WQUxJRF9QT1JUOiAvKiAweDAwNjEgKi8KKwkJZGVzYyA9ICJUYXJnZXQ6IEludmFsaWQgUG9ydCI7CisJCWJyZWFrOworCisJY2FzZSBNUElfSU9DU1RBVFVTX1RBUkdFVF9JTlZBTElEX0lPX0lOREVYOiAvKiAweDAwNjIgKi8KKwkJZGVzYyA9ICJUYXJnZXQgSW52YWxpZCBJTyBJbmRleDoiOworCQlicmVhazsKKworCWNhc2UgTVBJX0lPQ1NUQVRVU19UQVJHRVRfQUJPUlRFRDogLyogMHgwMDYzICovCisJCWRlc2MgPSAiVGFyZ2V0OiBBYm9ydGVkIjsKKwkJYnJlYWs7CisKKwljYXNlIE1QSV9JT0NTVEFUVVNfVEFSR0VUX05PX0NPTk5fUkVUUllBQkxFOiAvKiAweDAwNjQgKi8KKwkJZGVzYyA9ICJUYXJnZXQ6IE5vIENvbm4gUmV0cnlhYmxlIjsKKwkJYnJlYWs7CisKKwljYXNlIE1QSV9JT0NTVEFUVVNfVEFSR0VUX05PX0NPTk5FQ1RJT046IC8qIDB4MDA2NSAqLworCQlkZXNjID0gIlRhcmdldDogTm8gQ29ubmV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qKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKi8KKy8qICBGaWJyZSBDaGFubmVsIERpcmVjdCBBY2Nlc3MgdmFsdWVzICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqLworLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiovCisKKwljYXNlIE1QSV9JT0NTVEFUVVNfRkNfQUJPUlRFRDogLyogMHgwMDY2ICovCisJCWRlc2MgPSAiRkM6IEFib3J0ZWQiOworCQlicmVhazsKKworCWNhc2UgTVBJX0lPQ1NUQVRVU19GQ19SWF9JRF9JTlZBTElEOiAvKiAweDAwNjcgKi8KKwkJZGVzYyA9ICJGQzogUlggSUQgSW52YWxpZCI7CisJCWJyZWFrOworCisJY2FzZSBNUElfSU9DU1RBVFVTX0ZDX0RJRF9JTlZBTElEOiAvKiAweDAwNjggKi8KKwkJZGVzYyA9ICJGQzogRElEIEludmFsaWQiOworCQlicmVhazsKKworCWNhc2UgTVBJX0lPQ1NUQVRVU19GQ19OT0RFX0xPR0dFRF9PVVQ6IC8qIDB4MDA2OSAqLworCQlkZXNjID0gIkZDOiBOb2RlIExvZ2dlZCBPdXQiOworCQlicmVhazsKKworCWNhc2UgTVBJX0lPQ1NUQVRVU19GQ19FWENIQU5HRV9DQU5DRUxFRDogLyogMHgwMDZDICovCisJCWRlc2MgPSAiRkM6IEV4Y2hhbmdlIENhbmNlbGVkIjsKKwkJYnJlYWs7CisKKy8qKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqLworLyogIExBTiB2YWx1ZXMgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICovCisvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKio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qKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKi8KKy8qICBTZXJpYWwgQXR0YWNoZWQgU0NTSSB2YWx1ZXMgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAqLworLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiovCisKKwljYXNlIE1QSV9JT0NTVEFUVVNfU0FTX1NNUF9SRVFVRVNUX0ZBSUxFRDogLyogMHgwMDkwICovCisJCWRlc2MgPSAiU0FTOiBTTVAgUmVxdWVzdCBGYWlsZWQiOworCQlicmVhazsKKworCWNhc2UgTVBJX0lPQ1NUQVRVU19TQVNfU01QX0RBVEFfT1ZFUlJVTjogLyogMHgwMDkwICovCisJCWRlc2MgPSAiU0FTOiBTTVAgRGF0YSBPdmVycnVuIjsKIAkJYnJlYWs7CiAKIAlkZWZhdWx0OgogCQlkZXNjID0gIk90aGVycyI7CiAJCWJyZWFrOwogCX0KLQlpZiAoZGVzYyAhPSBOVUxMKQotCQlwcmludGsoTVlJT0Nfc19JTkZPX0ZNVCAiSU9DU3RhdHVzKDB4JTA0eCk6ICVzXG4iLCBpb2MtPm5hbWUsIHN0YXR1cywgZGVzYyk7CisKKwlpZiAoIWRlc2MpCisJCXJldHVybjsKKworCXByaW50ayhNWUlPQ19zX0lORk9fRk1UICJJT0NTdGF0dXMoMHglMDRYKTogJXNcbiIsIGlvYy0+bmFtZSwgc3RhdHVzLCBkZXNjKTsKIH0KKyNlbmRpZgogCiAvKj0tPS09LT0tPS09LT0tPS09LT0tPS09LT0tPS09LT0tPS09LT0tPS09LT0tPS09LT0tPS09LT0tPS09LT0tPS09LT0tPS09LT0tPSovCiBFWFBPUlRfU1lNQk9MKG1wdF9hdHRhY2gpOwpAQCAtNjQzNCw2ICs2OTk4LDcgQEAKIEVYUE9SVF9TWU1CT0wobXB0X2FsbG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19QQVJBTV9WTEFOVEFHX01BU0sgICAgICAgICAgMHhGRkZGCisjZGVmaW5lIFRTT19QQVJBTV9WTEFOX1NISUZUICAgICAgICAgICAgMTYKKworLyogdHNvcGwgZGVmaW5lcyAqLworI2RlZmluZSBUU09fUEFSQU1fRU9QX01BU0sgICAgICAgICAgICAgIDB4MDAwMQorI2RlZmluZSBUU09fUEFSQU1fRU9QX1NISUZUICAgICAgICAgICAgIDAKKyNkZWZpbmUgVFNPX1BBUkFNX0NPQUxFU0NFX01BU0sgICAgICAgICAweDAwMDEKKyNkZWZpbmUgVFNPX1BBUkFNX0NPQUxFU0NFX1NISUZUICAgICAgICAxCisjZGVmaW5lIFRTT19QQVJBTV9JTlNWTEFHX01BU0sgICAgICAgICAgMHgwMDAxCisjZGVmaW5lIFRTT19QQVJBTV9JTlNWTEFHX1NISUZUICAgICAgICAgMgorI2RlZmluZSBUU09fUEFSQU1fQ1VTVE9NQ0tTVU1fTUFTSyAgICAgIDB4MDAwMQorI2RlZmluZSBUU09fUEFSQU1fQ1VTVE9NQ0tTVU1fU0hJRlQgICAgIDMKKyNkZWZpbmUgVFNPX1BBUkFNX1NFR01FTlRfTUFTSyAgICAgICAgICAweDAwMDEKKyNkZWZpbmUgVFNPX1BBUkFNX1NFR01FTlRfU0hJRlQgICAgICAgICA0CisjZGVmaW5lIFRTT19QQVJBTV9JUENLU1VNX01BU0sgICAgICAgICAgMHgwMDAxCisjZGVmaW5lIFRTT19QQVJBTV9JUENLU1VNX1NISUZUICAgICAgICAgNQorI2RlZmluZSBUU09fUEFSQU1fVENQQ0tTVU1fTUFTSyAgICAgICAgIDB4MDAwMQorI2RlZmluZSBUU09fUEFSQU1fVENQQ0tTVU1fU0hJRlQgICAgICAgIDYKKyNkZWZpbmUgVFNPX1BBUkFNX1VEUENLU1VNX01BU0sgICAgICAgICAweDAwMDEKKyNkZWZpbmUgVFNPX1BBUkFNX1VEUENLU1VNX1NISUZUICAgICAgICA3CisjZGVmaW5lIFRTT19QQVJBTV9WTEFOVEFHR0VEX01BU0sgICAgICAgMHgwMDAxCisjZGVmaW5lIFRTT19QQVJBTV9WTEFOVEFHR0VEX1NISUZUICAgICAgOAorI2RlZmluZSBUU09fUEFSQU1fRVRIVFlQRV9NQVNLICAgICAgICAgIDB4MDAwMQorI2RlZmluZSBUU09fUEFSQU1fRVRIVFlQRV9TSElGVCAgICAgICAgIDkKKyNkZWZpbmUgVFNPX1BBUkFNX0lQSExfTUFTSyAgICAgICAgICAgICAweDAwMEYKKyNkZWZpbmUgVFNPX1BBUkFNX0lQSExfU0hJRlQgICAgICAgICAgICAxMAorI2RlZmluZSBUU09fUEFSQU1fVENQSERSTEVOX01BU0sgICAgICAgIDB4MDAwRgorI2RlZmluZSBUU09fUEFSQU1fVENQSERSTEVOX1NISUZUICAgICAgIDE0CisjZGVmaW5lIFRTT19QQVJBTV9IRFJGTEFHX01BU0sgICAgICAgICAgMHgwMDAxCisjZGVmaW5lIFRTT19QQVJBTV9IRFJGTEFHX1NISUZUICAgICAgICAgMTgKKyNkZWZpbmUgVFNPX1BBUkFNX01TU19NQVNLICAgICAgICAgICAgICAweDFGRkYKKyNkZWZpbmUgVFNPX1BBUkFNX01TU19TSElGVCAgICAgICAgICAgICAxOQorCisvKiBjc3VtcHUgZGVmaW5lcyAqLworI2RlZmluZSBDU1VNX1BBUkFNX0JVRkxFTl9NQVNLICAgICAgICAgIDB4M0ZGRgorI2RlZmluZSBDU1VNX1BBUkFNX0JVRkxFTl9TSElGVCAgICAgICAgIDAKKyNkZWZpbmUgQ1NVTV9QQVJBTV9ETUFJTlRfTUFTSyAgICAgICAgICAweDAwMDEKKyNkZWZpbmUgQ1NVTV9QQVJBTV9ETUFJTlRfU0hJRlQgICAgICAgICAxNAorI2RlZmluZSBDU1VNX1BBUkFNX1BLVElOVF9NQVNLICAgICAgICAgIDB4MDAwMQorI2RlZmluZSBDU1VNX1BBUkFNX1BLVElOVF9TSElGVCAgICAgICAgIDE1CisjZGVmaW5lIENTV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GVsc2UKKwkJCW5ldGlmX3J4KHNrYik7CisKKwkJLyogbGV0IHByb3RvY29sIGxheWVyIGZyZWUgc2tiICovCisJCWJ1ZmZlcl9pbmZvLT5za2IgPSBOVUxMOworCQlidWZmZXJfaW5mby0+YWxsb2NlZCA9IDA7CisJCXJyZC0+eHN6LnZhbGlkID0gMDsKKworCQlhZGFwdGVyLT5uZXRkZXYtPmxhc3RfcnggPSBqaWZmaWVzOworCX0KKworCWF0b21pY19zZXQoJnJyZF9yaW5nLT5uZXh0X3RvX2NsZWFuLCBycmRfbmV4dF90b19jbGVhbik7CisKKwlhdGwxX2FsbG9jX3J4X2J1ZmZlcnMoYWRhcHRlcik7CisKKwkvKiB1cGRhdGUgbWFpbGJveCA/ICovCisJaWYgKGNvdW50KSB7CisJCXUzMiB0cGRfbmV4dF90b191c2U7CisJCXUzMiByZmRfbmV4dF90b191c2U7CisJCXUzMiBycmRfbmV4dF90b19jbGVhbjsKKworCQlzcGluX2xvY2soJmFkYXB0ZXItPm1iX2xvY2spOworCisJCXRwZF9uZXh0X3RvX3VzZSA9IGF0b21pY19yZWFkKCZhZGFwdGVyLT50cGRfcmluZy5uZXh0X3RvX3VzZSk7CisJCXJmZF9uZXh0X3RvX3VzZSA9CisJCSAgICBhdG9taWNfcmVhZCgmYWRhcHRlci0+cmZkX3JpbmcubmV4dF90b191c2UpOworCQlycmRfbmV4dF90b19jbGVhbiA9CisJCSAgICBhdG9taWNfcmVhZCgmYWRhcHRlci0+cnJkX3JpbmcubmV4dF90b19jbGVhbik7CisJCXZhbHVlID0gKChyZmRfbmV4dF90b191c2UgJiBNQl9SRkRfUFJPRF9JTkRYX01BU0spIDw8CisJCQlNQl9SRkRfUFJPRF9JTkRYX1NISUZUKSB8CisgICAgICAgICAgICAgICAgICAgICAgICAoKHJyZF9uZXh0X3RvX2NsZWFuICYgTUJfUlJEX0NPTlNfSU5EWF9NQVNLKSA8PAorCQkJTUJfUlJEX0NPTlNfSU5EWF9TSElGVCkgfAor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XZkIik7CisJd2hpbGUgKDEpIHsKKwkJZG93bigmaW5mby0+cGluZyk7CisJCXBzM2F2X3NldF92aWRlb21vZGVfY29udChpbmZvLT5wczNhdl9tb2RlLAorCQkJCQkgaW5mby0+cHMzYXZfbW9kZV9vbGQpOworCQl1cCgmaW5mby0+cG9uZyk7CisJfQorCXJldHVybiAwOworfQorCitzdGF0aWMgaW50IHBzM2F2X3ZpZDJ0YWJsZV9pZChpbnQgdmlkKQoreworCWludCBpOworCisJZm9yIChpID0gMTsgaSA8IEFSUkFZX1NJWkUodmlkZW9fbW9kZV90YWJsZSk7IGkrKykKKwkJaWYgKHZpZGVvX21vZGVfdGFibGVbaV0udmlkID09IHZpZCkKKwkJCXJldHVybiBpOworCXJldHVybiAtMTsKK30KKworc3RhdGljIGludCBwczNhdl9yZXNiaXQydmlkKHUzMiByZXNfNTAsIHUzMiByZXNfNjApCit7CisJaW50IHZpZCA9IC0xOworCisJaWYgKHJlc181MCA+IHJlc182MCkgewkvKiBpZiByZXNfNTAgPT0gcmVzXzYwLCByZXNfNjAgd2lsbCBiZSB1c2VkICovCisJCWlmIChyZXNfNTAgJiBQUzNBVl9SRVNCSVRfMTkyMHgxMDgwUCkKKwkJCXZpZCA9IFBTM0FWX0NNRF9WSURFT19WSURfMTA4MFBfNTBIWjsKKwkJZWxzZSBpZiAocmVzXzUwICYgUFMzQVZfUkVTQklUXzE5MjB4MTA4MEkpCisJCQl2aWQgPSBQUzNBVl9DTURfVklERU9fVklEXzEwODBJXzUwSFo7CisJCWVsc2UgaWYgKHJlc181MCAmIFBTM0FWX1JFU0JJVF8xMjgweDcyMFApCisJCQl2aWQgPSBQUzNBVl9DTURfVklERU9fVklEXzcyMFBfNTBIWjsKKwkJZWxzZSBpZiAocmVzXzUwICYgUFMzQVZfUkVTQklUXzcyMHg1NzZQKQorCQkJdmlkID0gUFMzQVZfQ01EX1ZJREVPX1ZJRF81NzZQOworCQllbHNlCisJCQl2aWQgPSAtMTsKKwl9IGVsc2U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bW9uaXRvcl9pZFtpXSk7CisJcHJpbnRrKCJcbm1vbml0b3JfdHlwZTolMDJ4XG4iLCBpbmZvLT5tb25pdG9yX3R5cGUpOworCXByaW50aygibW9uaXRvcl9uYW1lOiIpOworCWZvciAoaSA9IDA7IGkgPCAxNjsgaSsrKQorCQlwcmludGsoIiVjIiwgaW5mby0+bW9uaXRvcl9uYW1lW2ldKTsKKworCS8qIHJlc29sdXRpb24gKi8KKwlwcmludGsoIlxucmVzb2x1dGlvbl82MDogYml0czolMDh4IG5hdGl2ZTolMDh4XG4iLAorCSAgICAgICBpbmZvLT5yZXNfNjAucmVzX2JpdHMsIGluZm8tPnJlc182MC5uYXRpdmUpOworCXByaW50aygicmVzb2x1dGlvbl81MDogYml0czolMDh4IG5hdGl2ZTolMDh4XG4iLAorCSAgICAgICBpbmZvLT5yZXNfNTAucmVzX2JpdHMsIGluZm8tPnJlc181MC5uYXRpdmUpOworCXByaW50aygicmVzb2x1dGlvbl9vdGhlcjogYml0czolMDh4IG5hdGl2ZTolMDh4XG4iLAorCSAgICAgICBpbmZvLT5yZXNfb3RoZXIucmVzX2JpdHMsIGluZm8tPnJlc19vdGhlci5uYXRpdmUpOworCXByaW50aygicmVzb2x1dGlvbl92ZXNhOiBiaXRzOiUwOHggbmF0aXZlOiUwOHhcbiIsCisJICAgICAgIGluZm8tPnJlc192ZXNhLnJlc19iaXRzLCBpbmZvLT5yZXNfdmVzYS5uYXRpdmUpOworCisJLyogY29sb3Igc3BhY2UgKi8KKwlwcmludGsoImNvbG9yIHNwYWNlICAgIHJnYjolMDJ4XG4iLCBpbmZvLT5jcy5yZ2IpOworCXByaW50aygiY29sb3Igc3BhY2UgeXV2NDQ0OiUwMnhcbiIsIGluZm8tPmNzLnl1djQ0NCk7CisJcHJpbnRrKCJjb2xvciBzcGFjZSB5dXY0MjI6JTAyeFxuIiwgaW5mby0+Y3MueXV2NDIyKTsKKworCS8qIGNvbG9yIGluZm8gKi8KKwlwcmludGsoImNvbG9yIG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2X3BhdGhfc2V2ZXJlZCwKKwkubWVzc2FnZV9wZW5kaW5nID0gbW9uX2l1Y3ZfbWVzc2FnZV9wZW5kaW5nLAogfTsKIAogLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKgogICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZmlsZSBvcGVyYXRpb25zICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKgogICoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqLwotc3RhdGljIGludAotbW9uX29wZW4oc3RydWN0IGlub2RlICppbm9kZSwgc3RydWN0IGZpbGUgKmZpbHApCitzdGF0aWMgaW50IG1vbl9vcGVuKHN0cnVjdCBpbm9kZSAqaW5vZGUsIHN0cnVjdCBmaWxlICpmaWxwKQogewotCWludCByYywgaTsKIAlzdHJ1Y3QgbW9uX3ByaXZhdGUgKm1vbnByaXY7CisJaW50IHJjOwogCiAJLyoKIAkgKiBvbmx5IG9uZSB1c2VyIGFsbG93ZWQKIAkgKi8KKwlyYyA9IC1FQlVTWTsKIAlpZiAodGVzdF9hbmRfc2V0X2JpdChNT05fSU5fVVNFLCAmbW9uX2luX3VzZSkpCi0JCXJldHVybiAtRUJVU1k7CisJCWdvdG8gb3V0OwogCisJcmMgPSAtRU5PTUVNOwogCW1vbnByaXYgPSBtb25fYWxsb2NfbWVtKCk7CiAJaWYgKCFtb25wcml2KQotCQlyZXR1cm4gLUVOT01FTTsKKwkJZ290byBvdXRfdXNlOwogCiAJLyoKLQkgKiBSZWdpc3RlciB3aXRoIElVQ1YgYW5kIGNvbm5lY3QgdG8gKk1PTklUT1Igc2VydmljZQorCSAqIENvbm5lY3QgdG8gKk1PTklUT1Igc2VydmljZQogCSAqLwotCW1vbnByaXYtPml1Y3ZfaGFuZGxlID0gaXVjdl9yZWdpc3Rlcl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CksKigoKGNoYXIqKXB0cikrNSksIFwKKwkJICAgKigoKGNoYXIqKXB0cikrNiksKigoKGNoYXIqKXB0cikrNyksKigoKGNoYXIqKXB0cikrOCksIFwKKwkJICAgKigoKGNoYXIqKXB0cikrOSksKigoKGNoYXIqKXB0cikrMTApLCooKChjaGFyKilwdHIpKzExKSwgXAorCQkgICAqKCgoY2hhciopcHRyKSsxMiksKigoKGNoYXIqKXB0cikrMTMpLCBcCisJCSAgICooKChjaGFyKilwdHIpKzE0KSwqKCgoY2hhciopcHRyKSsxNSkpOyBcCitQUklOVF8jI2ltcG9ydGFuY2UoaGVhZGVyICIlMDJ4ICUwMnggJTAyeCAlMDJ4ICAlMDJ4ICUwMnggJTAyeCAlMDJ4ICAiIFwKKwkJICAgIiUwMnggJTAyeCAlMDJ4ICUwMnggICUwMnggJTAyeCAlMDJ4ICUwMnhcbiIsIFwKKwkJICAgKigoKGNoYXIqKXB0cikrMTYpLCooKChjaGFyKilwdHIpKzE3KSwgXAorCQkgICAqKCgoY2hhciopcHRyKSsxOCksKigoKGNoYXIqKXB0cikrMTkpLCBcCisJCSAgICooKChjaGFyKilwdHIpKzIwKSwqKCgoY2hhciopcHRyKSsyMSksIFwKKwkJICAgKigoKGNoYXIqKXB0cikrMjIpLCooKChjaGFyKilwdHIpKzIzKSwgXAorCQkgICAqKCgoY2hhciopcHRyKSsyNCksKigoKGNoYXIqKXB0cikrMjUpLCBcCisJCSAgICooKChjaGFyKilwdHIpKzI2KSwqKCgoY2hhciopcHRyKSsyNyksIFwKKwkJICAgKigoKGNoYXIqKXB0cikrMjgpLCooKChjaGFyKilwdHIpKzI5KSwgXAorCQkgICAqKCgoY2hhciopcHRyKSszMCksKigoKGNoYXIqKXB0cikrMzEpKTsKKworc3RhdGljIGlubGluZSB2b2lkIGl1Y3ZfaGV4X2R1bXAodW5zaWduZWQgY2hhciAqYnVmLCBzaXplX3QgbGVuKQoreworCXNpemVfdCBpOworCisJZm9yIChpID0gMDsgaSA8IGxl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cDsKICAgICAgICAgc3RydWN0IG5ldF9kZXZpY2UgKm5kZXY7CiAgICAgICAgIHN0cnVjdCBuZXRpdWN2X3ByaXYgKnByaXY7CiAgICAgICAgIHN0cnVjdCBkZXZpY2UgKmRldjsKICAgICAgICAgY2hhciBuYW1lW0lGTkFNU0laXTsKLSAgICAgICAgY2hhciAqcDsKKwljb25zdCBjaGFyICpwOwogICAgICAgICBpbnQgaTsKIAogICAgICAgICBJVUNWX0RCRl9URVhUKHRyYWNlLCAzLCBfX0ZVTkNUSU9OX18pOwpAQCAtMjA3MiwzMyArMjA0OCwyNyBAQAogICAgICAgICBpZiAoY291bnQgPj0gSUZOQU1TSVopCiAgICAgICAgICAgICAgICAgY291bnQgPSBJRk5BTVNJWiAtIDE7OwogCi0gICAgICAgIGZvciAoaT0wLCBwPShjaGFyICopYnVmOyBpPGNvdW50ICYmICpwOyBpKyssIHArKykgewotICAgICAgICAgICAgICAgIGlmICgoKnAgPT0gJ1xuJykgfHwgKCpwID09ICcgJykpIHsKKwlmb3IgKGkgPSAwLCBwID0gYnVmOyBpIDwgY291bnQgJiYgKnA7IGkrKywgcCsrKSB7CisJCWlmICgqcCA9PSAnXG4nIHx8ICpwID09ICcgJykKICAgICAgICAgICAgICAgICAgICAgICAgIC8qIHRyYWlsaW5nIGxmLCBncnIgKi8KICAgICAgICAgICAgICAgICAgICAgICAgIGJyZWFrOwotICAgICAgICAgICAgICAgIH0gZWxzZSB7Ci0gICAgICAgICAgICAgICAgICAgICAgICBuYW1lW2ldPSpwOwotICAgICAgICAgICAgICAgIH0KKwkJbmFtZVtpXSA9ICpwOwogICAgICAgICB9CiAgICAgICAgIG5hbWVbaV0gPSAnXDAnOwogCi0JcmVhZF9sb2NrX2lycXNhdmUoJml1Y3ZfY29ubnMuaXVjdl9yd2xvY2ssIGZsYWdzKTsKLSAgICAgICAgd2hpbGUgKCpjbGlzdCkgewotICAgICAgICAgICAgICAgIG5kZXYgPSAoKmNsaXN0KS0+bmV0ZGV2OwotICAgICAgICAgICAgICAgIHByaXYgPSAoc3RydWN0IG5ldGl1Y3ZfcHJpdiopbmRldi0+cHJpdjsKKwlyZWFkX2xvY2tfYmgoJml1Y3ZfY29ubmVjdGlvbl9yd2xvY2spOworCWxpc3RfZm9yX2VhY2hfZW50cnkoY3AsICZpdWN2X2Nvbm5lY3Rpb25fbGlzdCwgbGlzdCkgeworCQluZGV2ID0gY3AtPm5ldGRldjsKKwkJcHJpdiA9IG5ldGRldl9wcml2KG5kZXYpOwogICAgICAgICAgICAgICAgIGRldiA9IHByaXYtPmRldjsKLQotICAgICAgICAgICAgICAgIGlmIChzdHJuY21wKG5hbWUsIG5kZXYtPm5hbWUsIGNvdW50KSkgewotICAgICAgICAgICAgICAgICAgICAgICAgY2xpc3QgPSAmKCgqY2xpc3QpLT5uZXh0KTsKLSAgICAgICAgICAgICAgICAgICAgICAgIGNvbnRpbnVlOwotICAgICAgICAgICAgICAgIH0KLQkJcmVhZF91bmxvY2tfaXJxcmVzdG9yZSgmaXVjdl9jb25ucy5pdWN2X3J3bG9jaywgZmxhZ3MpOworCQlpZiAoc3RybmNtcChuYW1lLCBuZGV2LT5uYW1lLCBjb3VudCkpCisJCQljb250aW51ZTsKKwkJcmVhZF91bmxvY2tfYmgoJml1Y3ZfY29ubmVjdGlvbl9yd2xvY2spOwogICAgICAgICAgICAgICAgIGlmIChuZGV2LT5mbGFncyAmIChJRkZfVVAgfCBJRkZfUlVOTklORykpIHsKLSAgICAgICAgICAgICAgICAgICAgICAgIFBSSU5UX1dBUk4oCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICJuZXRpdWN2OiBuZXQgZGV2aWNlICVzIGFjdGl2ZSB3aXRoIHBlZXIgJXNcbiIsCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIG5kZXYtPm5hbWUsIHByaXYtPmNvbm4tPnVzZXJpZCk7CisJCQlQUklOVF9XQVJOKCJuZXRpdWN2OiBuZXQgZGV2aWNlICVzIGFjdGl2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DX0lPQURSX0dBUCwgImFkdmFuc3lzIikpewogICAgICAgICAgICAgICAgICAgICAgICAgICAgIHByaW50aygKICJBZHZhblN5cyBTQ1NJOiBzcGVjaWZpZWQgSS9PIFBvcnQgMHglWCBpcyBidXN5XG4iLCBpb3ApOwogICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8qIERvbid0IHRyeSB0aGlzIEkvTyBwb3J0IHR3aWNlLiAqLwpAQCAtNDQxMyw2ICs0NDEzLDcgQEAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICBwcmludGsoCiAiQWR2YW5TeXMgU0NTSTogc3BlY2lmaWVkIEkvTyBQb3J0IDB4JVggaGFzIG5vIGFkYXB0ZXJcbiIsIGlvcCk7CiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLyogRG9uJ3QgdHJ5IHRoaXMgSS9PIHBvcnQgdHdpY2UuICovCisJCQkgICAgcmVsZWFzZV9yZWdpb24oaW9wLCBBU0NfSU9BRFJfR0FQKTsKICAgICAgICAgICAgICAgICAgICAgICAgICAgICBhc2NfaW9wb3J0W2lvcG9ydF0gPSAwOwogICAgICAgICAgICAgICAgICAgICAgICAgICAgIGdvdG8gaW9wb3J0X3RyeV9hZ2FpbjsKICAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7CkBAIC00NDMxLDYgKzQ0MzIsNyBAQAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICogJ2lvcG9ydCcgcGFzdCB0aGlzIGJvYXJkLgogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICovCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpb3BvcnQrKzsKKwkJCQkgcmVsZWFzZV9yZWdpb24oaW9wLCBBU0NfSU9BRFJfR0FQKTsKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGdvdG8gaW9wb3J0X3RyeV9hZ2FpbjsKICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9CiAgICAgICAgICAgICAgICAgICAgIC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NpZmRlZiBDT05GSUdfVEMKK3N0YXRpYyBpbnQgX19pbml0IGRlY19lc3BfdGNfcHJvYmUoc3RydWN0IGRldmljZSAqZGV2KTsKK3N0YXRpYyBpbnQgX19leGl0IGRlY19lc3BfdGNfcmVtb3ZlKHN0cnVjdCBkZXZpY2UgKmRldik7CisKK3N0YXRpYyBjb25zdCBzdHJ1Y3QgdGNfZGV2aWNlX2lkIGRlY19lc3BfdGNfdGFibGVbXSA9IHsKKyAgICAgICAgeyAiREVDICAgICAiLCAiUE1BWi1BQSAiIH0sCisgICAgICAgIHsgfQorfTsKK01PRFVMRV9ERVZJQ0VfVEFCTEUodGMsIGRlY19lc3BfdGNfdGFibGUpOworCitzdGF0aWMgc3RydWN0IHRjX2RyaXZlciBkZWNfZXNwX3RjX2RyaXZlciA9IHsKKyAgICAgICAgLmlkX3RhYmxlICAgICAgID0gZGVjX2VzcF90Y190YWJsZSwKKyAgICAgICAgLmRyaXZlciAgICAgICAgID0geworICAgICAgICAgICAgICAgIC5uYW1lICAgPSAiZGVjX2VzcCIsCisgICAgICAgICAgICAgICAgLmJ1cyAgICA9ICZ0Y19idXNfdHlwZSwKKyAgICAgICAgICAgICAgICAucHJvYmUgID0gZGVjX2VzcF90Y19wcm9iZSwKKyAgICAgICAgICAgICAgICAucmVtb3ZlID0gX19leGl0X3AoZGVjX2VzcF90Y19yZW1vdmUpLAorICAgICAgICB9LAorfTsKKworc3RhdGljIGludCBfX2luaXQgZGVjX2VzcF90Y19wcm9iZShzdHJ1Y3QgZGV2aWNlICpkZXYpCit7CisJaW50IHN0YXR1cyA9IGRlY19lc3BfcHJvYmUoZGV2KTsKKwlpZiAoIXN0YXR1cykKKwkJZ2V0X2RldmljZShkZXYpOworCXJldHVybiBzdGF0dXM7Cit9CisKK3N0YXRpYyBpbnQgX19leGl0IGRlY19lc3BfdGNfcmVtb3ZlKHN0cnVjdCBkZXZpY2UgKmRldikKK3sKKwlwdXRfZGV2aWNlKGRldik7CisJZGVjX2Vzc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m9yICJQbGVhc2UgZml4IDxhc20vYnl0ZW9yZGVyLmg+IgogI2VuZGlmCi0gICAgICAgIHUxNiAgICAgICAgICAgICBtYXhfc3BlZWQ7ICAgICAgICAgICAgICAvKiBNYXhpbXVtIHNwZWVkIHN1cHBvcnRlZCBpbiBLQnBzICovCisgICAgICAgIF9fYmUxNiAgICAgICAgICBtYXhfc3BlZWQ7ICAgICAgICAgICAgICAvKiBNYXhpbXVtIHNwZWVkIHN1cHBvcnRlZCBpbiBLQnBzICovCiAgICAgICAgIHU4ICAgICAgICAgICAgICByZXNlcnZlZDEwLCByZXNlcnZlZDExOwotICAgICAgICB1MTYgICAgICAgICAgICAgY3RsOyAgICAgICAgICAgICAgICAgICAgLyogQ29udGludW91cyBUcmFuc2ZlciBMaW1pdCBpbiBibG9ja3MgKi8KLSAgICAgICAgdTE2ICAgICAgICAgICAgIHNwZWVkOyAgICAgICAgICAgICAgICAgIC8qIEN1cnJlbnQgU3BlZWQsIGluIEtCcHMgKi8KLSAgICAgICAgdTE2ICAgICAgICAgICAgIGJ1ZmZlcl9zaXplOyAgICAgICAgICAgIC8qIEJ1ZmZlciBTaXplLCBpbiA1MTIgYnl0ZXMgKi8KKyAgICAgICAgX19iZTE2ICAgICAgICAgIGN0bDsgICAgICAgICAgICAgICAgICAgIC8qIENvbnRpbnVvdXMgVHJhbnNmZXIgTGltaXQgaW4gYmxvY2tzICovCisgICAgICAgIF9fYmUxNiAgICAgICAgICBzcGVlZDsgICAgICAgICAgICAgICAgICAvKiBDdXJyZW50IFNwZWVkLCBpbiBLQnBzICovCisgICAgICAgIF9fYmUxNiAgICAgICAgICBidWZmZXJfc2l6ZTsgICAgICAgICAgICAvKiBCdWZmZXIgU2l6ZSwgaW4gNTEyIGJ5dGVzICovCiAgICAgICAgIHU4ICAgICAgICAgICAgICByZXNlcnZlZDE4LCByZXNlcnZlZDE5OwogfSBvc3N0X2NhcGFiaWxpdGllc19wYWdlX3Q7CiAKQEAgLTM1Miw4ICszNTI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mVzZXJ2ZWQ7CiB9IG9zX2RhdF9lbnRyeV90OwpAQCAtNDEyLDIzICs0MTIsMjMgQEAKICAqIEFVWAogICovCiB0eXBlZGVmIHN0cnVjdCBvc19hdXhfcyB7Ci0gICAgICAgIF9fdTMyICAgICAgICAgICBmb3JtYXRfaWQ7ICAgICAgICAgICAgICAvKiBoYXJkd2FyZSBjb21wYWJpbGl0eSBBVVggaXMgYmFzZWQgb24gKi8KKyAgICAgICAgX19iZTMyICAgICAgICAgIGZvcm1hdF9pZDsgICAgICAgICAgICAgIC8qIGhhcmR3YXJlIGNvbXBhYmlsaXR5IEFVWCBpcyBiYXNlZCBvbiAqLwogICAgICAgICBjaGFyICAgICAgICAgICAgYXBwbGljYXRpb25fc2lnWzRdOyAgICAgLyogZHJpdmVyIHVzZWQgdG8gd3JpdGUgdGhpcyBtZWRpYSAqLwotICAgICAgICBfX3UzMiAgICAgICAgICAgaGR3cjsgICAgICAgICAgICAgICAgICAgLyogcmVzZXJ2ZWQgKi8KLSAgICAgICAgX191MzIgICAgICAgICAgIHVwZGF0ZV9mcmFtZV9jbnRyOyAgICAgIC8qIGZvciBjb25maWd1cmF0aW9uIGZyYW1lICovCisgICAgICAgIF9fYmUzMiAgICAgICAgICBoZHdyOyAgICAgICAgICAgICAgICAgICAvKiByZXNlcnZlZCAqLworICAgICAgICBfX2JlMzIgICAgICAgICAgdXBkYXRlX2ZyYW1lX2NudHI7ICAgICAgLyogZm9yIGNvbmZpZ3VyYXRpb24gZnJhbWUgKi8KICAgICAgICAgX191OCAgICAgICAgICAgIGZyYW1lX3R5cGU7CiAgICAgICAgIF9fdTggICAgICAgICAgICBmcmFtZV90eXBlX3Jlc2VydmVkOwogICAgICAgICBfX3U4ICAgICAgICAgICAgcmVzZXJ2ZWRfMThfMTlbMl07CiAgICAgICAgIG9zX3BhcnRpdGlvbl90ICBwYXJ0aXRpb247CiAgICAgICAgIF9fdTggICAgICAgICAgICByZXNlcnZlZF8zNl80M1s4XTsKLSAgICAgICAgX191MzIgICAgICAgICAgIGZyYW1lX3NlcV9udW07Ci0gICAgICAgIF9fdTMyICAgICAgICAgICBsb2dpY2FsX2Jsa19udW1faGlnaDsKLSAgICAgICAgX191MzIgICAgICAgICAgIGxvZ2ljYWxfYmxrX251bTsKKyAgICAgICAgX19iZTMyICAgICAgICAgIGZyYW1lX3NlcV9udW07CisgICAgICAgIF9fYmUzMiAgICAgICAgICBsb2dpY2FsX2Jsa19udW1faGlnaDsKKyAgICAgICAgX19iZTMyICAgICAgICAgIGxvZ2ljYWxfYmxrX251bTsKICAgICAgICAgb3NfZGF0X3QgICAgICAgIGRhdDsKICAgICAgICAgX191OCAgICAgICAgICAgIHJlc2VydmVkMTg4XzE5MVs0XTsKLSAgICAgICAgX191MzIgICAgICAgICAgIGZpbGVtYXJrX2NudDsKLSAgICAgICAgX191MzIgICAgICAgICAgIHBoeXNfZm07Ci0gICAgICAgIF9fdTMyICAgICAgICAgICBsYXN0X21hcmtfcHBvczsKKyAgICAgICAgX19iZTMyICAgICAgICAgIGZpbGVtYXJrX2NudDsKKyAgICAgICAgX19iZTMyICAgICAgICAgIHBoeXNfZm07CisgICAgICAgIF9fYmUzMiAgICAgICAgICBsYXN0X21hcmtfcHBvczsKICAgICAgICAgX191OCAgICAgICAgICAgIHJlc2VydmVkMjA0XzIyM1syMF07CiAKICAgICAgICAgLyoKQEAgLTQzNiw4ICs0MzYsOCBAQAogICAgICAgICAgKgogICAgICAgICAgKiBMaW51eCBzcGVjaWZpYyBmaWVsZHM6CiAgICAgICAgICAqLwotICAgICAgICAgX191MzIgICAgICAgICAgbmV4dF9tYXJrX3Bwb3M7ICAgICAgICAgLyogd2hlbiBrbm93biwgcG9pbnRzIHRvIG5leHQgbWFya2VyICovCi0JIF9fdTMyCQlsYXN0X21hcmtfbGJuOwkJLyogc3RvcmluZyBsb2dfYmxrX251bSBvZiBsYXN0IG1hcmsgaXMgZXh0ZW5kcyBBRFIgc3BlYyAqLworICAgICAgICAgX19iZTMy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gsCi0jaWYgIShMSU5VWF9WRVJTSU9OX0NPREUgPiBLRVJORUxfVkVSU0lPTigyLDUsNzMpKQotCQkJCQkgaW50ICAgICBob3N0bm8sCi0jZW5kaWYKIAkJCQkJIGludCAgICAgaW5vdXQpOwogc3RhdGljIGludCBuc3BfcXVldWVjb21tYW5kKHN0cnVjdCBzY3NpX2NtbmQgKlNDcG50LAogCQkJICAgIHZvaWQgKCogZG9uZSkoc3RydWN0IHNjc2lfY21uZCAqU0NwbnQpKTsKQEAgLTM1Niw3ICszNDYsNiBAQAogc3RhdGljIGludCAgX19pbml0IG5zcF9jc19pbml0KHZvaWQpOwogc3RhdGljIHZvaWQgX19leGl0IG5zcF9jc19leGl0KHZvaWQpOwogCi0KIC8qIERlYnVnICovCiAjaWZkZWYgTlNQX0RFQlVHCiBzdGF0aWMgdm9pZCBzaG93X2NvbW1hbmQgKHN0cnVjdCBzY3NpX2NtbmQgKlNDcG50KTsKQEAgLTQwMSw3ICszOTAsNiBAQAogCUJVUlNUX01FTTMyID0gMiwKIH07CiAKLQogLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqCiAgKiBTQ1NJIG1lc3NhYWdlCiAgKi8KQEAgLTQxMyw2MiArNDAxLDggQEAKIAogI2RlZmluZSBNU0dfRVhUX1NEVFIgICAgICAgICAweDAxCiAKLQotLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqCi0gKiBDb21wYXRpYmlsaXR5IGZ1bmN0aW9ucwotICovCi0KLS8qIGZvciBLZXJuZWwgMi40ICovCi0jaWYgKExJTlVYX1ZFUlNJT05fQ09ERSA8IEtFUk5FTF9WRVJTSU9OKDIsNiwwKSkKLSMgIGRlZmluZSBzY3NpX3JlZ2lzdGVyX2hvc3QodGVtcGxhdGUpICAgc2NzaV9yZWdpc3Rlcl9tb2R1bGUo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NDOTMgU0NTSSBkcml2ZXIiKTsKQEAgLTEyMyw2ICsxMjksMTMgQEAKICAqICAgICAgICAgICAgICAgICAgICBkZWZpbmVzIGluIHdkMzNjOTMuaAogICogLSAgY2xvY2s6eCAgICAgICAgLXggPSBjbG9jayBpbnB1dCBpbiBNSHogZm9yIFdEMzNjOTMgY2hpcC4gTm9ybWFsIHZhbHVlcwogICogICAgICAgICAgICAgICAgICAgIHdvdWxkIGJlIGZyb20gOCB0aHJvdWdoIDIwLiBEZWZhdWx0IGlzIDguCisgKiAtICBidXJzdDp4ICAgICAgICAteCA9IDEgdG8gdXNlIEJ1cnN0IE1vZGUgKG9yIERlbWFuZC1Nb2RlKSBETUEsIHggPSAwIHRvIHVzZQorICogICAgICAgICAgICAgICAgICAgIFNpbmdsZSBCeXRlIERNQSwgd2hpY2ggaXMgdGhlIGRlZmF1bHQuIEFyZ3VtZW50IGlzCisgKiAgICAgICAgICAgICAgICAgICAgb3B0aW9uYWwgLSBpZiBub3QgcHJlc2VudCwgc2FtZSBhcyAiYnVyc3Q6MSIuCisgKiAtICBmYXN0OnggICAgICAgICAteCA9IDEgdG8gZW5hYmxlIEZhc3QgU0NTSSwgd2hpY2ggaXMgb25seSBlZmZlY3RpdmUgd2l0aAorICogICAgICAgICAgICAgICAgICAgIGlucHV0LWNsb2NrIGRpdmlzb3IgNCAoV0QzM0M5M19GU18xNl8yMCksIHggPSAwIHRvIGRpc2FibGUKKyAqICAgICAgICAgICAgICAgICAgICBpdCwgd2hpY2ggaXMgdGhlIGRlZmF1bHQuICBBcmd1bWVudCBpcyBvcHRpb25hbCAtIGlmIG5vdAorICogICAgICAgICAgICAgICAgICAgIHByZXNlbnQsIHNhbWUgYXMgImZhc3Q6MSIuCiAgKiAtICBuZXh0ICAgICAgICAgICAtTm8gYXJndW1lbnQuIFVzZWQgdG8gc2VwYXJhdGUgYmxvY2tzIG9mIGtleXdvcmRzIHdoZW4KICAqICAgICAgICAgICAgICAgICAgICB0aGVyZSdzIG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CRVIyMDAwKSAgICAgICAgKz0gY3liZXIyMDAwZmIubwogb2JqLSQoQ09ORklHX0ZCX1BNMikgICAgICAgICAgICAgICs9IHBtMmZiLm8KIG9iai0kKENPTkZJR19GQl9QTTMpCQkgICs9IHBtM2ZiLm8KQEAgLTQzLDE3ICs0MiwxNiBAQAogb2JqLSQoQ09ORklHX0ZCX01CWCkJCSAgKz0gbWJ4Lwogb2JqLSQoQ09ORklHX0ZCX0k4MTApICAgICAgICAgICAgICs9IHZnYXN0YXRlLm8KIG9iai0kKENPTkZJR19GQl9ORU9NQUdJQykgICAgICAgICArPSBuZW9mYi5vIHZnYXN0YXRlLm8KLW9iai0kKENPTkZJR19GQl9WSVJHRSkgICAgICAgICAgICArPSB2aXJnZWZiLm8KIG9iai0kKENPTkZJR19GQl8zREZYKSAgICAgICAgICAgICArPSB0ZGZ4ZmIubwogb2JqLSQoQ09ORklHX0ZCX0NPTlRST0wpICAgICAgICAgICs9IGNvbnRyb2xmYi5vCiBvYmotJChDT05GSUdfRkJfUExBVElOVU0pICAgICAgICAgKz0gcGxhdGludW1mYi5vCiBvYmotJChDT05GSUdfRkJfVkFMS1lSSUUpICAgICAgICAgKz0gdmFsa3lyaWVmYi5vCiBvYmotJChDT05GSUdfRkJfQ1Q2NTU1MCkgICAgICAgICAgKz0gY2hpcHNmYi5vCiBvYmotJChDT05GSUdfRkJfSU1TVFQpICAgICAgICAgICAgKz0gaW1zdHRmYi5vCi1vYmotJChDT05GSUdfRkJfUzNUUklPKSAgICAgICAgICAgKz0gUzN0cmlvZmIubwogb2JqLSQoQ09ORklHX0ZCX0ZNMikgICAgICAgICAgICAgICs9IGZtMmZiLm8KIG9iai0kKENPTkZJR19GQl9DWUJMQSkgICAgICAgICAgICArPSBjeWJsYWZiLm8KIG9iai0kKENPTkZJR19GQl9UUklERU5UKSAgICAgICAgICArPSB0cmlkZW50ZmIubworb2JqLSQoQ09ORklHX0ZCX1MzKSAgICAgICAgICAgICAgICs9IHMzZmIubyB2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KLS8qCi0gKgotICogTG93IGxldmVsIGluaXRpYWxpemF0aW9uIHJvdXRpbmVzIGZvciB0aGUgQ3liZXJWaXNpb242NCBncmFwaGljcyBjYXJkCi0gKgotICogTW9zdCBvZiB0aGUgZm9sbG93aW5nIGNvZGUgaXMgZnJvbSBjdmlzaW9uX2NvcmUuYwotICoKLSAqLwotCi0jZGVmaW5lIE1BWFBJWEVMQ0xPQ0sgMTM1MDAwMDAwIC8qIHNhZmV0eSAqLwotCi0jaWZkZWYgQ1ZfQUdHUkVTU0lWRV9USU1JTkcKLWxvbmcgY3Y2NF9tZW1jbGsgPSA1NTAwMDAwMDsKLSNlbHNlCi1sb25nIGN2NjRfbWVtY2xrID0gNTAwMDAwMDA7Ci0jZW5kaWYKLQotLyoqKioqKioqKioqKioqKioqKioqKi8KLQotc3RhdGljIHVuc2lnbmVkIGNoYXIgY2xvY2tzW109ewotICAweDEzLCAweDYxLCAweDZiLCAweDZkLCAweDUxLCAweDY5LCAweDU0LCAweDY5LAotICAweDRmLCAweDY4LCAweDZiLCAweDZiLCAweDE4LCAweDYxLCAweDdiLCAweDZjLAotICAweDUxLCAweDY3LCAweDI0LCAweDYyLCAweDU2LCAweDY3LCAweDc3LCAweDZhLAotICAweDFkLCAweDYxLCAweDUzLCAweDY2LCAweDZiLCAweDY4LCAweDc5LCAweDY5LAotICAweDdjLCAweDY5LCAweDdmLCAweDY5LCAweDIyLCAweDYxLCAweDU0LCAweDY1LAotICAweDU2LCAweDY1LCAweDU4LCAweDY1LCAweDY3LCAweDY2LCAweDQxLCAweDYzLAotICAweDI3LCAweDYxLCAweDEzLCAweDQxLCAweDM3LCAweDYyLCAweDZiLCAweDRkLAotICAweDIzLCAweDQzLCAweDUxLCAweDQ5LCAweDc5LCAweDY2LCAweDU0LCAweDQ5LAotICAweDdkLCAweDY2LCAweDM0LCAweDU2LCAweDRmLCAweDYzLCAweDFmLCAweDQyLAotICAweDZiLCAweDRiLCAweDdlLCAweDRkLCAweDE4LCAweDQxLCAweDJhLCAweDQzLAotICAweDdiLCAweDRjLCAweDc0LCAweDRiLCAweDUxLCAweDQ3LCAweDY1LCAweDQ5LAotICAweDI0LCAweDQyLCAweDY4LCAweDQ5LCAweDU2LCAweDQ3LCAweDc1LCAweDRhLAotICAweDc3LCAweDRhLCAweDMxLCAweDQzLCAweDFkLCAweDQxLCAweDcxLCAweDQ5LAotICAweDUzLCAweDQ2LCAweDI5LCAweDQyLCAweDZiLCAweDQ4LCAweDFmLCAweDQxLAotICAweDc5LCAweDQ5LCAweDZmLCAweDQ4LCAweDdjLCAweDQ5LCAweDM4LCAweDQzLAotICAweDdmLCAweDQ5LCAweDVkLCAweDQ2LCAweDIyLCAweDQxLCAweDUzLCAweDQ1LAotICAweDU0LCAweDQ1LCAweDU1LCAweDQ1LCAweDU2LCAweDQ1LCAweDU3LCAweDQ1LAotICAweDU4LCAweDQ1LCAweDI1LCAweDQxLCAweDY3LCAweDQ2LCAweDViLCAweDQ1LAotICAweDQxLCAweDQzLCAweDc4LCAweDQ3LCAweDI3LCAweDQxLCAweDUxLCAweDQ0LAotICAweDEzLCAweDIxLCAweDdkLCAweDQ3LCAweDM3LCAweDQyLCAweDcxLCAweDQ2LAotICAweDZiLCAweDJkLCAweDE0LCAweDIxLCAweDIzLCAweDIzLCAweDdkLCAweDJmLAotICAweDUxLCAweDI5LCAweDYxLCAweDJiLCAweDc5LCAweDQ2LCAweDFkLCAweDIyLAotICAweDU0LCAweDI5LCAweDQ1LCAweDI3LCAweDdkLCAweDQ2LCAweDdmLCAweDQ2LAotICAweDRmLCAweDQzLCAweDJmLCAweDQxLCAweDFmLCAweDIyLCAweDZhLCAweDJiLAotICAweDZiLCAweDJiLCAweDViLCAweDI5LCAweDdlLCAweDJkLCAweDY1LCAweDQ0LAotICAweDE4LCAweDIxLCAweDVlLCAweDI5LCAweDJhLCAweDIzLCAweDQ1LCAweDI2LAotICAweDdiLCAweDJjLCAweDE5LCAweDIxLCAweDc0LCAweDJiLCAweDc1LCAweDJiLAotICAweDUxLCAweDI3LCAweDNmLCAweDI1LCAweDY1LCAweDI5LCAweDQwLCAweDI1LAotICAweDI0LCAweDIyLCAweDQxLCAweDI1LCAweDY4LCAweDI5LCAweDQyLCAweDI1LAotICAweDU2LCAweDI3LCAweDdlLCAweDJiLCAweDc1LCAweDJhLCAweDFjLCAweDIxLAotICAweDc3LCAweDJhLCAweDRmLCAweDI2LCAweDMxLCAweDIzLCAweDZmLCAweDI5LAotICAweDFkLCAweDIxLCAweDMyLCAweDIzLCAweDcxLCAweDI5LCAweDcyLCAweDI5LAotICAweDUzLCAweDI2LCAweDY5LCAweDI4LCAweDI5LCAweDIyLCAweDc1LCAweDI5LAotICAweDZiLCAweDI4LCAweDFmLCAweDIxLCAweDFmLCAweDIxLCAweDZkLCAweDI4LAotICAweDc5LCAweDI5LCAweDJiLCAweDIyLCAweDZmLCAweDI4LCAweDU5LCAweDI2LAotICAweDdjLCAweDI5LCAweDdkLCAweDI5LCAweDM4LCAweDIzLCAweDIxLCAweDIxLAotICAweDdmLCAweDI5LCAweDM5LCAweDIzLCAweDVkLCAweDI2LCAweDc1LCAweDI4LAotICAweDIyLCAweDIxLCAweDc3LCAweDI4LCAweDUzLCAweDI1LCAweDZjLCAweDI3LAotICAweDU0LCAweDI1LCAweDYxLCAweDI2LCAweDU1LCAweDI1LCAweDMwLCAweDIyLAotICAweDU2LCAweDI1LCAweDYzLCAweDI2LCAweDU3LCAweDI1LCAweDcxLCAweDI3LAotICAweDU4LCAweDI1LCAweDdmLCAweDI4LCAweDI1LCAweDIxLCAweDc0LCAweDI3LAotICAweDY3LCAweDI2LCAweDQwLCAweDIzLCAweDViLCAweDI1LCAweDI2LCAweDIxLAotICAweDQxLCAweDIzLCAweDM0LCAweDIyLCAweDc4LCAweDI3LCAweDZiLCAweDI2LAotICAweDI3LCAweDIxLCAweDM1LCAweDIyLCAweDUxLCAweDI0LCAweDdiLCAweDI3LAotICAweDEzLCAweDEsICAweDEzLCAweDEsICAweDd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HZicyAtIDE7Ci0gICAgVlNTID0gdnNzOwotICAgIFZTRSA9IHZzZTsKLSAgICBWQkUgPSB2YmU7Ci0gICAgVlQgID0gdnQgLSAyOwotICB9IGVsc2UgewotI2Vsc2UKLSAgICB7Ci0jZW5kaWYKLSAgICBIQlMgPSBobXVsICogKHhyZXMgLyA4KTsKLSAgICBIQkUgPSBobXVsICogKCh4cmVzLzgpICsgKGhmcm9udC84KSArIChoc3luYy84KSArIChoYmFjay84KSAtIDIpOwotICAgIEhTUyA9IGhtdWwgKiAoKHhyZXMvOCkgKyAoaGZyb250LzgpICsgMik7Ci0gICAgSFNFID0gaG11bCAqICgoeHJlcy84KSArIChoZnJvbnQvOCkgKyAoaHN5bmMvOCkgKyAxKTsKLSAgICBIVCAgPSBobXVsICogKCh4cmVzLzgpICsgKGhmcm9udC84KSArIChoc3luYy84KSArIChoYmFjay84KSk7Ci0JCi0gICAgVkJTID0geXJlczsKLSAgICBWQkUgPSB5cmVzICsgdmZyb250ICsgdnN5bmMgKyB2YmFjayAtIDI7Ci0gICAgVlNTID0geXJlcyArIHZmcm9udCAtIDE7Ci0gICAgVlNFID0geXJlcyArIHZmcm9udCArIHZzeW5jIC0gMTsKLSAgICBWVCAgPSB5cmVzICsgdmZyb250ICsgdnN5bmMgKyB2YmFjayAtIDI7Ci0gIH0KLQotICB3Yl82NCAocmVncywgRUNSX0FEVl9GVU5DX0NOVEwsIChURVhUID8gMHgwMCA6IDB4MzEpKTsKLQkKLSAgaWYgKFRFWFQpCi0gICAgSERFID0gKCh2aWRlb19tb2RlLT54cmVzICsgZnggLSAxKSAvIGZ4KSAtIDE7Ci0gIGVsc2UKLSAgICBIREUgPSAodmlkZW9fbW9kZS0+eHJlcyArIDMpICogaG11bCAvIDggLSAxOwotCQotICBWREUgPSB2aWRlb19tb2RlLT55cmVzIC0gMTsKLQotICBXQ3J0IChyZWdzLCBDUlRfSURfSFdHQ19NT0RFLCAweDAwKTsKLSAgV0NydCAocmVncywgQ1JUX0l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N0YXJ0LCBvZmZzZXQgPj4gUEFHRV9TSElGVCwKKwkJCSAgICBzaXplLCB2bWEtPnZtX3BhZ2VfcHJvdCkpCisJCXJldHVybiAtRUFHQUlOOworCisJcHJpbnRrKEtFUk5fREVCVUcgInBzM2ZiOiBtbWFwIGZyYW1lYnVmZmVyIFAoJWx4KS0+ViglbHgpXG4iLCBvZmZzZXQsCisJICAgICAgIHZtYS0+dm1fc3RhcnQpOworCXJldHVybiAwOworfQorCisgICAgLyoKKyAgICAgKiBCbGFuayB0aGUgZGlzcGxheQorICAgICAqLworCitzdGF0aWMgaW50IHBzM2ZiX2JsYW5rKGludCBibGFuaywgc3RydWN0IGZiX2luZm8gKmluZm8pCit7CisJaW50IHJldHZhbDsKKworCURQUklOVEsoIiVzOiBibGFuazolZFxuIiwgX19GVU5DVElPTl9fLCBibGFuayk7CisJc3dpdGNoIChibGFuaykgeworCWNhc2UgRkJfQkxBTktfUE9XRVJET1dOOgorCWNhc2UgRkJfQkxBTktfSFNZTkNfU1VTUEVORDoKKwljYXNlIEZCX0JMQU5LX1ZTWU5DX1NVU1BFTkQ6CisJY2FzZSBGQl9CTEFOS19OT1JNQUw6CisJCXJldHZhbCA9IHBzM2F2X3ZpZGVvX211dGUoMSk7CS8qIG11dGUgb24gKi8KKwkJaWYgKCFyZXR2YWwpCisJCQlwczNmYi5pc19ibGFua2VkID0gMTsKKwkJYnJlYWs7CisKKwlkZWZhdWx0OgkJLyogdW5ibGFuayAqLworCQlyZXR2YWwgPSBwczNhdl92aWRlb19tdXRlKDApOwkvKiBtdXRlIG9mZiAqLworCQlpZiAoIXJldHZhbCkKKwkJCXBzM2ZiLmlzX2JsYW5rZWQgPSAwOworCQlicmVhazsKKwl9CisJcmV0dXJuIHJldHZhbDsKK30KKworc3RhdGljIGludCBwczNmYl9nZXRfdmJsYW5rKHN0cnVjdCBmYl92YmxhbmsgKnZibGFuaykKK3sKKwltZW1zZXQodmJsYW5rLCAwLCBzaXplb2YoJnZibGFuaykpOworCXZibGFuay0+ZmxhZ3MgPSBGQl9WQkxBTktfSEFWRV9WU1lOQzsKKwlyZXR1cm4gMDsKK30KKworaW50IHBzM2ZiX3dhaXRfZm9yX3ZzeW5jKHUzMiBjcnRjKQoreworCWludCByZXQ7CisJdTY0IGNvdW50OworCisJY291bnQgPSBwczNmYi52YmxhbmtfY291bnQ7CisJcmV0ID0gd2FpdF9ldmVudF9pbnRlcnJ1cHRpYmxlX3RpbWVvdXQocHMzZmIud2FpdF92c3luYywKKwkJCQkJICAgICAgIGNvdW50ICE9IHBzM2ZiLnZibGFua19jb3VudCwKKwkJCQkJICAgICAgIEhaIC8gMTApOworCWlmICghcmV0KQorCQlyZXR1cm4gLUVUSU1FRE9VVDsKKworCXJldHVybiAwOworfQorCitFWFBPUlRfU1lNQk9MX0dQTChwczNmYl93YWl0X2Zvcl92c3luYyk7CisKK3ZvaWQgcHMzZmJfZmxpcF9jdGwoaW50IG9uKQoreworCWlmIChvbikgeworCQlpZiAoYXRvbWljX3JlYWQoJnBzM2ZiLmV4dF9mbGlwKSA+IDApIHsKKwkJCWF0b21pY19kZWMoJnBzM2ZiLmV4dF9mbGlwKTsKKwkJfQorCX0gZWxzZSB7CisJCWF0b21pY19pbmMoJnBzM2ZiLmV4dF9mbGlwKTsKKwl9Cit9CisKK0VYUE9SVF9TWU1CT0xfR1BMKHBzM2ZiX2ZsaXBfY3RsKTsKKworICAgIC8qCisgICAgICogaW9jdGwKKyAgICAgKi8KKworc3RhdGljIGludCBwczNmYl9pb2N0bChzdHJ1Y3QgZmJfaW5mbyAqaW5mbywgdW5zaWduZWQgaW50IGNtZCwKKwkJICAgICAgIHVuc2lnbmVkIGxvbmcgYXJnKQoreworCXZvaWQgX191c2VyICphcmdwID0gKHZvaWQgX191c2VyICopYXJnOworCXUzMiB2YWwsIG9sZF9tb2RlOworCWludCByZXR2YWwgPSAtRUZBVUxUOworCisJc3dpdGNoIChjbWQpIHsKKwljYXNlIEZCSU9HRVRfVkJMQU5LOg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sMTYgKzEyNjEsMTYgQEAKIAogICAgaWYoU2lTX1ByLT5DaGlwVHlwZSA+PSBYR0lfMjApIHsKICAgICAgIC8qIFhHSSBST01zIGRvbid0IHF1YWxpZnkgKi8KLSAgICAgIHJldHVybiBGQUxTRTsKKyAgICAgIHJldHVybiBmYWxzZTsKICAgIH0gZWxzZSBpZihTaVNfUHItPkNoaXBUeXBlID49IFNJU183NjEpIHsKICAgICAgIC8qIEkgdmVyeSBtdWNoIGFzc3VtZSA3NjEsIDM0MCBhbmQgbmV3ZXIgd2lsbCB1c2UgbmV3IGxheW91dCAqLwotICAgICAgcmV0dXJuIFRSVUU7CisgICAgICByZXR1cm4gdHJ1ZTsKICAgIH0gZWxzZSBpZihTaVNfUHItPkNoaXBUeXBlID49IFNJU182NjEpIHsKICAgICAgIGlmKChST01BZGRyWzB4MWFdID09ICdOJykgJiYKIAkgKFJPTUFkZHJbMHgxYl0gPT0gJ2UnKSAmJgogCSAoUk9NQWRkclsweDFjXSA9PSAndycpICYmCiAJIChST01BZGRyWzB4MWRdID09ICdWJykpIHsKLQkgcmV0dXJuIFRSVUU7CisJIHJldHVybiB0cnVlOwogICAgICAgfQogICAgICAgcm9tdmVyc29mZnMgPSBST01BZGRyWzB4MTZdIHwgKFJPTUFkZHJbMHgxN10gPDwgOCk7CiAgICAgICBpZihyb212ZXJzb2ZmcykgewpAQCAtMTI4MCwxNyArMTI4MCwxNyBAQAogCSB9CiAgICAgICB9CiAgICAgICBpZigocm9tdm1haiAhPSAwKSB8fCAocm9tdm1pbiA+PSA5MikpIHsKLQkgcmV0dXJuIFRSVUU7CisJIHJldHVybiB0cnVlOwogICAgICAgfQogICAgfSBlbHNlIGlmKElTX1NJUzY1MDc0MCkgewogICAgICAgaWYoKFJPTUFkZHJbMHgxYV0gPT0gJ04nKSAmJgogCSAoUk9NQWRkclsweDFiXSA9PSAnZScpICYmCiAJIChST01BZGRyWzB4MWNdID09ICd3JykgJiYKIAkgKFJPTUFkZHJbMHgxZF0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Q3NSwxMyArMzQ3NSwxMyBAQAogCiAgICAgICAvKiBEb24ndCBuZWVkIHZiZmxhZ3MgaGVyZTsgY2hlY2tzIGRvbmUgZWFybGllciAqLwogICAgICAgTW9kZU5vID0gU2lTX0dldE1vZGVOdW1iZXIocFNjcm4sIG1vZGUsIHBTaVMtPlZCRmxhZ3MpOwotICAgICAgaWYoIU1vZGVObykgcmV0dXJuIEZBTFNFOworICAgICAgaWYoIU1vZGVObykgcmV0dXJuIGZhbHNlOwogCiAgICAgICB4Zjg2RHJ2TXNnVmVyYihwU2Nybi0+c2NybkluZGV4LCBYX0lORk8sIDMsICJTZXR0aW5nIHN0YW5kYXJkIG1vZGUgMHgleFxuIiwgTW9kZU5vKTsKIAogICAgfQogCi0gICByZXR1cm4oU2lTU2V0TW9kZShTaVNfUHIsIHBTY3JuLCBNb2RlTm8sIFRSVUUpKTsKKyAgIHJldHVybihTaVNTZXRNb2RlKFNpU19QciwgcFNjcm4sIE1vZGVObywgdHJ1ZSkpOwogfQogCiAvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqLwpAQCAtMzQ4OSw5ICszNDg5LDkgQEAKIC8qICAgICAgICAgICBmb3IgRHVhbC1IZWFkIG1vZGVzICAgICAgICAgICAgICovCiAvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqLwogCi1CT09MRUFOCitib29sCiBTaVNCSU9TU2V0TW9kZUNSVDIoc3RydWN0IFNpU19Qcml2YXRlICpTaVNfUHIsIFNjcm5JbmZvUHRyIHBTY3JuLAotICAgICAgICAgICAgICAgRGlzcGxheU1vZGVQdHIgbW9kZSwgQk9PTEVBTiBJc0N1c3RvbSkKKyAgICAgICAgICAgICAgIERpc3BsYXlNb2RlUHRyIG1vZGUsIGJvb2wgSXNDdXN0b20pCiB7CiAgICBTSVNJT0FERFJFU1MgQmFzZUFkZHIgPSBTaVNfUHItPklPQWRkcmVzczsKICAgIFNJU1B0ciAgcFNpUy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19Qci0+VXNlQ3VzdG9tTW9kZSkgewotICAgICAgaWYoIShTaVNfU2VhcmNoTW9kZUlEKFNpU19QciwgJk1vZGVObywgJk1vZGVJZEluZGV4KSkpIHJldHVybiBGQUxTRTsKKyAgICAgIGlmKCEoU2lTX1NlYXJjaE1vZGVJRChTaVNfUHIsICZNb2RlTm8sICZNb2RlSWRJbmRleCkpKSByZXR1cm4gZmFsc2U7CiAgICB9IGVsc2UgewogICAgICAgTW9kZUlkSW5kZXggPSAwOwogICAgfQpAQCAtMzY1OCw3ICszNjU4LDcgQEAKIAogICAgU2lTX0hhbmRsZTc2MChTaVNfUHIpOwogCi0gICByZXR1cm4gVFJVRTsKKyAgIHJldHVybiB0cnVlOwogfQogCiAvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqLwpAQCAtMzY2Niw5ICszNjY2LDkgQEAKIC8qICAgICAgICAgICBmb3IgRHVhbC1IZWFkIG1vZGVzICAgICAgICAgICAgICovCiAvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqLwogCi1CT09MRUFOCitib29sCiBTaVNCSU9TU2V0TW9kZUNSVDEoc3RydWN0IFNpU19Qcml2YXRlICpTaVNfUHIsIFNjcm5JbmZvUHRyIHBTY3JuLAotICAgICAgICAgICAgICAgICAgIERpc3BsYXlNb2RlUHRyIG1vZGUsIEJPT0xFQU4gSXNDdXN0b20pCisgICAgICAgICAgICAgICAgICAgRGlzcGxheU1vZGVQdHIgbW9kZSwgYm9vbCBJc0N1c3RvbSkKIHsKICAgIFNJU0lPQUREUkVTUyBCYXNlQWRkciA9IFNpU19Qci0+SU9BZGRyZXNzOwogICAgU0lTUHRyICBwU2lTID0gU0lTUFRSKHBTY3JuKTsKQEAgLTM2NzcsMTAgKzM2NzcsMTAgQEAKICNpZmRlZiBTSVNEVUFMSEVBRAogICAgU0lTRW50UHRyIHBTaVNFbnQgPSBwU2lTLT5lbnRpdHlQcml2YXRlOwogICAgdW5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otCUQocHJpbnRrKCIgICAgICAgIDB4JXAsIC8qIHJhbmdlX25leHQgICovXG4iLCBuLT5yYW5nZV9uZXh0KSk7Ci0JRChwcmludGsoIn1cbiIpKTsKLX0KLQotI2VuZGlmCi0KLS8qIFByaW50IHRoZSBjb250ZW50cyBvZiBhIHJhdyBpbm9kZS4gICovCi1zdGF0aWMgdm9pZAotamZmc19wcmludF9yYXdfaW5vZGUoc3RydWN0IGpmZnNfcmF3X2lub2RlICpyYXdfaW5vZGUpCi17Ci0JRChwcmludGsoImpmZnNfcmF3X2lub2RlOiBpbm9kZSBudW1iZXI6ICV1XG4iLCByYXdfaW5vZGUtPmlubykpOwotCUQocHJpbnRrKCJ7XG4iKSk7Ci0JRChwcmludGsoIiAgICAgICAgMHglMDh4LCAvKiBtYWdpYyAgKi9cbiIsIHJhd19pbm9kZS0+bWFnaWMpKTsKLQlEKHByaW50aygiICAgICAgICAweCUwOHgsIC8qIGlubyAgKi9cbiIsIHJhd19pbm9kZS0+aW5vKSk7Ci0JRChwcmludGsoIiAgICAgICAgMHglMDh4LCAvKiBwaW5vICAqL1xuIiwgcmF3X2lub2RlLT5waW5vKSk7Ci0JRChwcmludGsoIiAgICAgICAgMHglMDh4LCAvKiB2ZXJzaW9uICAqL1xuIiwgcmF3X2lub2RlLT52ZXJzaW9uKSk7Ci0JRChwcmludGsoIiAgICAgICAgMHglMDh4LCAvKiBtb2RlICAqL1xuIiwgcmF3X2lub2RlLT5tb2RlKSk7Ci0JRChwcmludGsoIiAgICAgICAgMHglMDR4LCAgICAgLyogdWlkICAqL1xuIiwgcmF3X2lub2RlLT51aWQpKTsKLQlEKHByaW50aygiICAgICAgICAweCUwNHgsICAgICAvKiBnaWQgICovXG4iLCByYXdfaW5vZGUtPmdpZCkpOwotCUQocHJpbnRrKCIgICAgICAgIDB4JTA4eCwgLyogYXRpbWUgICovXG4iLCByYXdfaW5vZGUtPmF0aW1lKSk7Ci0JRChwcmludGsoIiAgICAgICAgMHglMDh4LCAvKiBtdGltZSAgKi9cbiIsIHJhd19pbm9kZS0+bXRpbWUpKTsKLQlEKHByaW50aygiICAgICAgICAweCUwOHgsIC8qIGN0aW1lICAqL1xuIiwgcmF3X2lub2RlLT5jdGltZSkpOwotCUQocHJpbnRrKCIgICAgICAgIDB4JTA4eCwgLyogb2Zmc2V0ICAqL1xuIiwgcmF3X2lub2RlLT5vZmZzZXQpKTsKLQlEKHByaW50aygiICAgICAgICAweCUwOHgsIC8qIGRzaXplICAqL1xuIiwgcmF3X2lub2RlLT5kc2l6ZSkpOwotCUQocHJpbnRrKCIgICAgICAgIDB4JTA4eCwgLyogcnNpemUgICovXG4iLCByYXdfaW5vZGUtPnJzaXplKSk7Ci0JRChwcmludGsoIiAgICAgICAgMHglMDJ4LCAgICAgICAvKiBuc2l6ZSAgKi9cbiIsIHJhd19pbm9kZS0+bnNpemUpKTsKLQlEKHByaW50aygiICAgICAgICAweCUwMngsICAgICAgIC8qIG5saW5rICAqL1xuIiwgcmF3X2lub2RlLT5ubGluaykpOwotCUQocHJpbnRrKCIgICAgICAgIDB4JTAyeCwgICAgICAgLyogc3BhcmUgICovXG4iLAotCQkgcmF3X2lub2RlLT5zcGFyZSkpOwotCUQocHJpbnRrKCIgICAgICAgICV1LCAgICAgICAgICAvKiByZW5hbWUgICovXG4iLAotCQkgcmF3X2lub2RlLT5yZW5hbWUpKTsKLQlEKHByaW50aygiICAgICAgICAldSwgICAgICAgICAgLyogZGVsZXRlZCAgKi9cbiIsCi0JCSByYXdfaW5vZGUtPmRlbGV0ZWQpKTsKLQlEKHByaW50aygiICAgICAgICAweCUwMngsICAgICAgIC8qIGFjY3VyYXRlICAqL1xuIiwKLQkJIHJhd19pbm9kZS0+YWNjdXJhdGUpKTsKLQlEKHByaW50aygiICAgICAgICAweCUwOHgsIC8qIGRjaGtzdW0gICovXG4iLCByYXdfaW5vZGUtPmRjaGtzdW0pKTsKLQlEKHByaW50aygiICAgICAgICAweCUwNHgsICAgICAvKiBuY2hrc3Vt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KLQlpZiAoIShzcGFjZSA9IGttYWxsb2MoaW5kZW50ICsgMSwgR0ZQX0tFUk5FTCkpKSB7Ci0JCXByaW50aygiamZmc19wcmludF90cmVlKCk6IE91dCBvZiBtZW1vcnkhXG4iKTsKLQkJcmV0dXJuOwotCX0KLQotCW1lbXNldChzcGFjZSwgJyAnLCBpbmRlbnQpOwotCXNwYWNlW2luZGVudF0gPSAnXDAnOwotCi0JZm9yIChmID0gZmlyc3RfZmlsZTsgZjsgZiA9IGYtPnNpYmxpbmdfbmV4dCkgewotCQlkaXIgPSBTX0lTRElSKGYtPm1vZGUpOwotCQlwcmludGsoIiVzJXMlcyAoaW5vOiAldSwgaGlnaGVzdF92ZXJzaW9uOiAldSwgc2l6ZTogJXUpXG4iLAotCQkgICAgICAgc3BhY2UsIChmLT5uYW1lID8gZi0+bmFtZSA6ICIiKSwgKGRpciA/ICIvIiA6ICIiKSwKLQkJICAgICAgIGYtPmlubywgZi0+aGlnaGVzdF92ZXJzaW9uLCBmLT5zaXplKTsKLQkJaWYgKGRpcikgewotCQkJamZmc19wcmludF90cmVlKGYtPmNoaWxkcmVuLCBpbmRlbnQgKyAyKTsKLQkJfQotCX0KLQotCWtmcmVlKHNwYWNlKTsKLX0KLQotCi0jaWYgZGVmaW5lZChKRkZTX01FTU9SWV9ERUJVRykgJiYgSkZGU19NRU1PUllfREVCVUcKLXZvaWQKLWpmZnNfcHJpbnRfbWVtb3J5X2FsbG9jYXRpb25fc3RhdGlzdGljcyh2b2lkKQotewotCXN0YXRpYyBsb25nIHByaW50b3V0OwotCXByaW50aygiX19fX19fX18gTWVtb3J5IHByaW50b3V0ICMlbGQgX19fX19fX19cbiIsICsrcHJpbnRvdXQpOwotCXByaW50aygibm9famZmc19maWxlID0gJWxkXG4iLCBub19qZmZzX2ZpbGUpOwotCXByaW50aygibm9famZmc19ub2RlID0gJWxkXG4iLCBub19qZmZzX25vZGUpOwotCXByaW50aygibm9famZmc19jb250cm9sID0gJWxkXG4iLCBub19q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mNsdWRlIDxhc20vZXJybm8uaD4KKworc3RhdGljIGlubGluZSBpbnQgZ3Bpb19yZXF1ZXN0KHVuc2lnbmVkIGdwaW8sIGNvbnN0IGNoYXIgKmxhYmVsKQoreworCXJldHVybiBvbWFwX3JlcXVlc3RfZ3BpbyhncGlvKTsKK30KKworc3RhdGljIGlubGluZSB2b2lkIGdwaW9fZnJlZSh1bnNpZ25lZCBncGlvKQoreworCW9tYXBfZnJlZV9ncGlvKGdwaW8pOworfQorCitzdGF0aWMgaW5saW5lIGludCBfX2dwaW9fc2V0X2RpcmVjdGlvbih1bnNpZ25lZCBncGlvLCBpbnQgaXNfaW5wdXQpCit7CisJaWYgKGNwdV9jbGFzc19pc19vbWFwMigpKSB7CisJCWlmIChncGlvID4gT01BUF9NQVhfR1BJT19MSU5FUykKKwkJCXJldHVybiAtRUlOVkFMOworCX0gZWxzZSB7CisJCWlmIChncGlvID4gKE9NQVBfTUFYX0dQSU9fTElORVMgKyAxNiAvKiBNUFVJTyAqLykpCisJCQlyZXR1cm4gLUVJTlZBTDsKKwl9CisJb21hcF9zZXRfZ3Bpb19kaXJlY3Rpb24oZ3BpbywgaXNfaW5wdXQpOworCXJldHVybiAwOworfQorCitzdGF0aWMgaW5saW5lIGludCBncGlvX2RpcmVjdGlvbl9pbnB1dCh1bnNpZ25lZCBncGlvKQoreworCXJldHVybiBfX2dwaW9fc2V0X2RpcmVjdGlvbihncGlvLCAxKTsKK30KKworc3RhdGljIGlubGluZSBpbnQgZ3Bpb19kaXJlY3Rpb25fb3V0cHV0KHVuc2lnbmVkIGdwaW8pCit7CisJcmV0dXJuIF9fZ3Bpb19zZXRfZGlyZWN0aW9uKGdwaW8sIDApOworfQorCitzdGF0aWMgaW5saW5lIGludCBncGlvX2dldF92YWx1ZSh1bnNpZ25lZCBncGlvKQoreworCXJldHVybiBvbWFwX2dldF9ncGlvX2RhdGFpbihncGlvKTsKK30KKworc3RhdGljIGlubGluZSB2b2lkIGdwaW9fc2V0X3Zhb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ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgXAogICAgICAgICAoeyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgXAotICAgICAgICAgICAgICAgIGNvbnN0IHJlZ2lzdGVyIHR5cGVvZigqKHApKSBfX3IxIGFzbSgicjEiKSA9ICh4KTsgICAgICAgXAotICAgICAgICAgICAgICAgIGNvbnN0IHJlZ2lzdGVyIHR5cGVvZigqKHApKSAqX19wIGFzbSgicjAiKSA9IChwKTsgICAgICAgXAorICAgICAgICAgICAgICAgIHJlZ2lzdGVyIGNvbnN0IHR5cGVvZigqKHApKSBfX3IxIGFzbSgicjEiKSA9ICh4KTsgICAgICAgXAorICAgICAgICAgICAgICAgIHJlZ2lzdGVyIGNvbnN0IHR5cGVvZigqKHApKSAqX19wIGFzbSgicjAiKSA9IChwKTsgICAgICAgXAogICAgICAgICAgICAgICAgIHJlZ2lzdGVyIGludCBfX2UgYXNtKCJyMCIpOyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgXAogICAgICAgICAgICAgICAgIHN3aXRjaCAoc2l6ZW9mKCooX19wKSkpIHsgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgXAogICAgICAgICAgICAgICAgIGNhc2UgMTogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgXApAQCAtMTcwLDggKzE3MCw4IEBACiAKICNkZWZpbmUgcHV0X3VzZXIoeCxwKQkJCQkJCQlcCiAJKHsJCQkJCQkJCVwKLQkJY29uc3QgcmVnaXN0ZXIgdHlwZW9mKCoocCkpIF9fcjEgYXNtKCJyMSIpID0gKHgpOwlcCi0JCWNvbnN0IHJlZ2lzdGVyIHR5cGVvZigqKHApKSAqX19wIGFzbSgicjAiKSA9IChwKTsJXAorCQlyZWdpc3RlciBjb25zdCB0eXBlb2YoKihwKSkgX19yMSBhc20oInIxIikgPSAoeCk7CVwKKwkJcmVnaXN0ZXIgY29uc3Qg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0WzhdOyAgICAvLyBWTUlfSW5pdCBqdW1wIHBvaW50CisJY2hhciAgICBnZXRfcmVsb2NbOF07ICAgLy8gVk1JX0dldFJlbG9jYXRpb25JbmZvIGp1bXAgcG9pbnQKK30gX19hdHRyaWJ1dGVfXygocGFja2VkKSk7CisKK3N0cnVjdCBwbnBfaGVhZGVyIHsKKyAgICAgICAgY2hhciBzaWdbNF07CisgICAgICAgIGNoYXIgcmV2OworICAgICAgICBjaGFyIHNpemU7CisgICAgICAgIHNob3J0IG5leHQ7CisgICAgICAgIHNob3J0IHJlczsKKyAgICAgICAgbG9uZyBkZXZJRDsKKyAgICAgICAgdW5zaWduZWQgc2hvcnQgbWFudWZhY3R1cmVyX29mZnNldDsKKyAgICAgICAgdW5zaWduZWQgc2hvcnQgcHJvZHVjdF9vZmZzZXQ7Cit9IF9fYXR0cmlidXRlX18oKHBhY2tlZCkpOworCitzdHJ1Y3QgcGNpX2hlYWRlciB7CisgICAgICAgIGNoYXIgc2lnWzRdOworICAgICAgICBzaG9ydCB2ZW5kb3JJRDsKKyAgICAgICAgc2hvcnQgZGV2aWNlSUQ7CisgICAgICAgIHNob3J0IHZwZERhdGE7CisgICAgICAgIHNob3J0IHNpemU7CisgICAgICAgIGNoYXIgcmV2OworICAgICAgICBjaGFyIGNsYXNzOworICAgICAgICBjaGFyIHN1YmNsYXNzOworICAgICAgICBjaGFyIGludGVyZmFjZTsKKyAgICAgICAgc2hvcnQgY2h1bmtzOworICAgICAgICBjaGFyIHJvbV92ZXJzaW9uX21pbjsKKyAgICAgICAgY2hhciByb21fdmVyc2lvbl9tYWo7CisgICAgICAgIGNoYXIgY29kZXR5cGU7CisgICAgICAgIGNoYXIgbGFzdFJvbTsKKyAgICAgICAgc2hvcnQgcmVzZXJ2ZWQ7Cit9IF9fYXR0cmlidXRlX18oKHBhY2tlZCkpOworCisvKiBGdW5jdGlvbiBwcm90b3R5cGVzIGZvciBib290c3RyYXBwaW5nICovCitleHRlcm4gdm9pZCB2bWl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8xMCAgICAgICAgICAgICAgICAgMgorI2RlZmluZSBTTklfQlJEXzEwTkVXICAgICAgICAgICAgICAzCisjZGVmaW5lIFNOSV9CUkRfVE9XRVJfT0FTSUMgICAgICAgIDQKKyNkZWZpbmUgU05JX0JSRF9NSU5JVE9XRVIgICAgICAgICAgNQorI2RlZmluZSBTTklfQlJEX1BDSV9UT1dFUiAgICAgICAgICA2CisjZGVmaW5lIFNOSV9CUkRfUk0yMDAgICAgICAgICAgICAgIDcKKyNkZWZpbmUgU05JX0JSRF9QQ0lfTVRPV0VSICAgICAgICAgOAorI2RlZmluZSBTTklfQlJEX1BDSV9ERVNLVE9QICAgICAgICA5CisjZGVmaW5lIFNOSV9CUkRfUENJX1RPV0VSX0NQTFVTICAgMTAKKyNkZWZpbmUgU05JX0JSRF9QQ0lfTVRPV0VSX0NQTFVTICAxMQorCisvKiBSTTQwMCBjcHUgdHlwZXMgKi8KKyNkZWZpbmUgU05JX0NQVV9NODAyMSAgICAgICAgICAgMHgwMQorI2RlZmluZSBTTklfQ1BVX004MDMwICAgICAgICAgICAweDA0CisjZGVmaW5lIFNOSV9DUFVfTTgwMzEgICAgICAgICAgIDB4MDYKKyNkZWZpbmUgU05JX0NQVV9NODAzNCAgICAgICAgICAgMHgwZgorI2RlZmluZSBTTklfQ1BVX004MDM3ICAgICAgICAgICAweDA3CisjZGVmaW5lIFNOSV9DUFVfTTgwNDAgICAgICAgICAgIDB4MDUKKyNkZWZpbmUgU05JX0NQVV9NODA0MyAgICAgICAgICAgMHgwOQorI2RlZmluZSBTTklfQ1BVX004MDUwICAgICAgICAgICAweDBiCisjZGVmaW5lIFNOSV9DUFVfTTgwNTMgICAgICAgICAgIDB4MGQKKwogI2RlZmluZSBTTklfUE9SVF9CQVNFCQkweGI0MDAwMDAwCiAKKyNpZm5kZWYgX19NSVBTRUxfXworLyoKKyAqIEFTSUMgUENJIHJlZ2lzdGVycyBmb3IgYmlnIGVuZGlhbiBjb25maWd1cmF0aW9uLgorICovCis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lIFBTM0FWX0NJRF9FVkVOVF9IRENQX0FVVEggICAgICAweDEwMDAwMDA1CisjZGVmaW5lIFBTM0FWX0NJRF9FVkVOVF9IRENQX0VSUk9SICAgICAweDEwMDAwMDA2CisKKyNkZWZpbmUgUFMzQVZfQ0lEX0FWQl9QQVJBTSAgICAgICAgICAgIDB4MDQwMDAwMDEKKworLyogbWF4IGJhY2tlbmQgcG9ydHMgKi8KKyNkZWZpbmUgUFMzQVZfSERNSV9NQVggICAgICAgICAgICAgICAgIDIJLyogSERNSV8wIEhETUlfMSAqLworI2RlZmluZSBQUzNBVl9BVk1VTFRJX01BWCAgICAgICAgICAgICAgMQkvKiBBVk1VTFRJXzAgKi8KKyNkZWZpbmUgUFMzQVZfQVZfUE9SVF9NQVggICAgICAgICAgICAgIChQUzNBVl9IRE1JX01BWCArIFBTM0FWX0FWTVVMVElfTUFYKQorI2RlZmluZSBQUzNBVl9PUFRfUE9SVF9NQVggICAgICAgICAgICAgMQkvKiBTUERJRjAgKi8KKyNkZWZpbmUgUFMzQVZfSEVBRF9NQVggICAgICAgICAgICAgICAgIDIJLyogSEVBRF9BIEhFQURfQiAqLworCisvKiBudW0gb2YgcGt0IGZvciBQUzNBVl9DSURfQVZCX1BBUkFNICovCisjZGVmaW5lIFBTM0FWX0FWQl9OVU1fVklERU8gICAgICAgICAgICBQUzNBVl9IRUFEX01BWAorI2RlZmluZSBQUzNBVl9BVkJfTlVNX0FVRElPICAgICAgICAgICAgMAkvKiBub3Qgc3VwcG9ydGVkICovCisjZGVmaW5lIFBTM0FWX0FWQl9OVU1fQVZfVklERU8gICAgICAgICBQUzNBVl9BVl9QT1JUX01BWAorI2RlZmluZSBQUzNBVl9BVkJfTlVNX0FWX0FVRElPICAgICAgICAgUFMzQVZfSERNSV9NQVgKKworI2RlZmluZSBQUzNBVl9NVVRFX1BPUlRfTUFYICAgICAgICAgICAgMQkvKiBudW0gb2YgcG9ydHMgaW4gbXV0ZSBwa3QgKi8KKworLyogZXZlbnR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hdGUgKi8KIH07CiAKKy8qIHRoaXMgd2FzIHNhYTcxMzRfaXIgYW5kIGJ0dHZfaXIsIG1vdmVkIGhlcmUgZm9yCisgKiByYzUgZGVjb2RpbmcuICovCitzdHJ1Y3QgY2FyZF9pciB7CisJc3RydWN0IGlucHV0X2RldiAgICAgICAgKmRldjsKKwlzdHJ1Y3QgaXJfaW5wdXRfc3RhdGUgICBpcjsKKwljaGFyICAgICAgICAgICAgICAgICAgICBuYW1lWzMyXTsKKwljaGFyICAgICAgICAgICAgICAgICAgICBwaHlzWzMyXTsKKworCS8qIFVzdWFsIGdwaW8gc2lnbmFsbGluZyAqLworCisJdTMyICAgICAgICAgICAgICAgICAgICAgbWFza19rZXljb2RlOworCXUzMiAgICAgICAgICAgICAgICAgICAgIG1hc2tfa2V5ZG93bjsKKwl1MzIgICAgICAgICAgICAgICAgICAgICBtYXNrX2tleXVwOworCXUzMiAgICAgICAgICAgICAgICAgICAgIHBvbGxpbmc7CisJdTMyICAgICAgICAgICAgICAgICAgICAgbGFzdF9ncGlvOworCWludAkJCXNoaWZ0X2J5OworCWludAkJCXN0YXJ0OyAvLyBXaGF0IHNob3VsZCBSQzVfU1RBUlQoKSBiZQorCWludAkJCWFkZHI7IC8vIFdoYXQgUkM1X0FERFIoKSBzaG91bGQgYmUuCisJaW50CQkJcmM1X2tleV90aW1lb3V0OworCWludAkJCXJjNV9yZW1vdGVfZ2FwOworCXN0cnVjdCB3b3JrX3N0cnVjdCAgICAgIHdvcms7CisJc3RydWN0IHRpbWVyX2xpc3QgICAgICAgdGltZXI7CisKKwkvKiBSQzUgZ3BpbyAqLworCXUzMiByYzVfZ3BpbzsKKwlzdHJ1Y3QgdGltZXJfbGlzdCB0aW1lcl9lbmQ7CS8qIHRpbWVyX2VuZCBmb3IgY29kZSBjb21wbGV0aW9uICovCisJc3RydWN0IHRpbWVyX2xpc3QgdGltZXJfa2V5dXA7CS8qIHRpbWVyX2VuZCBmb3Iga2V5IHJlbGVhc2UgKi8K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JKi8KICNkZWZpbmUgQV9GWEdQUkVHQkFTRQkJMHg0MDAJCS8qIEF1ZGlneSBHUFJzLCAweDQwMCB0byAweDVmZgkJCSovCkBAIC04ODYsNiArOTYxLDI5MyBAQAogI2RlZmluZSBBX0hJV09SRF9SRVNVTFRfTUFTSwkweDAwN2ZmMDAwCiAjZGVmaW5lIEFfSElXT1JEX09QQV9NQVNLCTB4MDAwMDA3ZmYKIAorLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKi8KKy8qIEVNVTEwMTBtIEhBTkEgRlBHQSByZWdpc3RlcnMJCQkJCQkJCQkqLworLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKi8KKyNkZWZpbmUgRU1VX0hBTkFfREVTVEhJCQkweDAwCS8qIDAwMDB4eHggIDMgYml0cyBMaW5rIERlc3RpbmF0aW9uICovCisjZGVmaW5lIEVNVV9IQU5BX0RFU1RMTwkJMHgwMQkvKiAwMHh4eHh4ICA1IGJpdHMgKi8KKyNkZWZpbmUgRU1VX0hBTkFfU1JDSEkJCTB4MDIJLyogMDAwMHh4eCAgMyBiaXRzIExpbmsgU291cmNlICovCisjZGVmaW5lIEVNVV9IQU5BX1NSQ0xPCQkweDAzCS8qIDAweHh4eHggIDUgYml0cyAqLworI2RlZmluZSBFTVVfSEFOQV9ET0NLX1BXUgkweDA0CS8qIDAwMDAwMHggIDEgYml0cyBBdWRpbyBEb2NrIHBvd2VyICovCisjZGVmaW5lIEVNVV9IQU5BX0RPQ0tfUFdSX09OCQkweDAxIC8qIEF1ZGlvIERvY2sgcG93ZXIgb24gKi8KKyNkZWZpbmUgRU1VX0hBTkFfV0NMT0NLCQkweDA1CS8qIDAwMDB4eHggIDMgYml0cyBXb3JkIENsb2NrI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SU4gV29yZCBjbG9jaywgbG93ZXIgNiBiaXRzICovCisKKyNkZWZpbmUgRU1VX0hBTkFfV0NfQk5DX0xPCTB4MmMJLyogMHh4eHh4eCAgNiBiaXQgIEJOQyBJTiBXb3JkIGNsb2NrLCBsb3dlciA2IGJpdHMgKi8KKyNkZWZpbmUgRU1VX0hBTkFfV0NfQk5DX0hJCTB4MmQJLyogMHh4eHh4eCAgNiBiaXQgIEJOQyBJTiBXb3JkIGNsb2NrLCB1cHBlciA2IGJpdHMgKi8KKworI2RlZmluZSBFTVVfSEFOQTJfV0NfU1BESUZfSEkJMHgyZQkvKiAweHh4eHh4ICA2IGJpdCAgSEFOQTIgU1BESUYgSU4gV29yZCBjbG9jaywgdXBwZXIgNiBiaXRzICovCisjZGVmaW5lIEVNVV9IQU5BMl9XQ19TUERJRl9MTwkweDJmCS8qIDB4eHh4eHggIDYgYml0ICBIQU5BMiBTUERJRiBJTiBXb3JkIGNsb2NrLCBsb3dlciA2IGJpdHMgKi8KKy8qIDB4MzAgLSAweDNmIFVudXNlZCBSZWFkIG9ubHkgcmVnaXN0ZXJzICovCisKKy8qKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiovCisvKiBFTVUxMDEwbSBIQU5BIERlc3RpbmF0aW9ucwkJCQkJCQkJCSovCisvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqLworI2RlZmluZSBFTVVfRFNUX0FMSUNFMl9FTVUzMl8wCTB4MDAwZgkvKiAxNiBFTVUzMiBjaGFubmVscyB0byBBbGljZTIgKzAgdG8gKzB4ZiAqLworI2RlZmluZSBFTVVfRFNUX0FMSUNFMl9FTVUzMl8xCTB4MDAwMAkvKiAxNiBFTVUzMiBjaGFubmVscyB0byBBbGljZTIgKzA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Zmllc190b19jbG9ja190KGxvbmcgeCkKK3sKKyNpZiAoVElDS19OU0VDICUgKE5TRUNfUEVSX1NFQyAvIFVTRVJfSFopKSA9PSAwCisJcmV0dXJuIHggLyAoSFogLyBVU0VSX0haKTsKKyNlbHNlCisJdTY0IHRtcCA9ICh1NjQpeCAqIFRJQ0tfTlNFQzsKKwlkb19kaXYodG1wLCAoTlNFQ19QRVJfU0VDIC8gVVNFUl9IWikpOworCXJldHVybiAobG9uZyl0bXA7CisjZW5kaWYKK30KK0VYUE9SVF9TWU1CT0woamlmZmllc190b19jbG9ja190KTsKKwordW5zaWduZWQgbG9uZyBjbG9ja190X3RvX2ppZmZpZXModW5zaWduZWQgbG9uZyB4KQoreworI2lmIChIWiAlIFVTRVJfSFopPT0wCisJaWYgKHggPj0gfjBVTCAvIChIWiAvIFVTRVJfSFopKQorCQlyZXR1cm4gfjBVTDsKKwlyZXR1cm4geCAqIChIWiAvIFVTRVJfSFopOworI2Vsc2UKKwl1NjQgamlmOworCisJLyogRG9uJ3Qgd29ycnkgYWJvdXQgbG9zcyBvZiBwcmVjaXNpb24gaGVyZSAuLiAqLworCWlmICh4ID49IH4wVUwgLyBIWiAqIFVTRVJfSFopCisJCXJldHVybiB+MFVMOworCisJLyogLi4gYnV0IGRvIHRyeSB0byBjb250YWluIGl0IGhlcmUgKi8KKwlqaWYgPSB4ICogKHU2NCkgSFo7CisJZG9fZGl2KGppZiwgVVNFUl9IWik7CisJcmV0dXJuIGppZjsKKyNlbmRpZgorfQorRVhQT1JUX1NZTUJPTChjbG9ja190X3RvX2ppZmZpZXMpOworCit1NjQgamlmZmllc182NF90b19jbG9ja190KHU2NCB4KQoreworI2lmIChUSUNLX05TRUMgJSAoTlNFQ19QRVJfU0VDIC8gVVNFUl9IWikpID09IDAKKwlkb19kaXYoeCwgSFogLyBVU0VSX0haKTsKKyNlbHNlCisJLyoKKwkgKiBUaGVyZSBhcmUgYmV0dGVyIHdheXMgdGhhdCBkb24ndCBvdmVyZmx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Rldi0+bmV4dF9ldmVudDsKKwl9CisKKwlpZiAoZXhwaXJlcy50djY0ID09IEtUSU1FX01BWCkKKwkJcmV0dXJuIDA7CisKKwlyZXR1cm4gdGlja19icm9hZGNhc3Rfc2V0X2V2ZW50KGV4cGlyZXMsIDApOworfQorCisvKgorICogSGFuZGxlIG9uZXNob3QgbW9kZSBicm9hZGNhc3RpbmcKKyAqLworc3RhdGljIHZvaWQgdGlja19oYW5kbGVfb25lc2hvdF9icm9hZGNhc3Qoc3RydWN0IGNsb2NrX2V2ZW50X2RldmljZSAqZGV2KQoreworCXN0cnVjdCB0aWNrX2RldmljZSAqdGQ7CisJY3B1bWFza190IG1hc2s7CisJa3RpbWVfdCBub3c7CisJaW50IGNwdTsKKworCXNwaW5fbG9jaygmdGlja19icm9hZGNhc3RfbG9jayk7CithZ2FpbjoKKwlkZXYtPm5leHRfZXZlbnQudHY2NCA9IEtUSU1FX01BWDsKKwltYXNrID0gQ1BVX01BU0tfTk9ORTsKKwlub3cgPSBrdGltZV9nZXQoKTsKKwkvKiBGaW5kIGFsbCBleHBpcmVkIGV2ZW50cyAqLworCWZvciAoY3B1ID0gZmlyc3RfY3B1KHRpY2tfYnJvYWRjYXN0X29uZXNob3RfbWFzayk7IGNwdSAhPSBOUl9DUFVTOworCSAgICAgY3B1ID0gbmV4dF9jcHUoY3B1LCB0aWNrX2Jyb2FkY2FzdF9vbmVzaG90X21hc2spKSB7CisJCXRkID0gJnBlcl9jcHUodGlja19jcHVfZGV2aWNlLCBjcHUpOworCQlpZiAodGQtPmV2dGRldi0+bmV4dF9ldmVudC50djY0IDw9IG5vdy50djY0KQorCQkJY3B1X3NldChjcHUsIG1hc2spOworCX0KKworCS8qCisJICogV2FrZXVwIHRoZSBjcHVzIHdoaWNoIGhhdmUgYW4gZXhwaXJlZCBldmVudC4gVGhlIGJyb2FkY2FzdAorCSAqIGRldmljZSBpcyByZXByb2dyYW1tZWQgaW4gdGhlIHJldHVybiBmcm9tIGlkbGUgY29kZ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AgICAgICAgICByZXR1cm4gLUVQRVJNOwotICAgICAgICAgICAgICAgICAgICAgICAgaWYgKHNhLT5zYXRfZmFtaWx5ICE9IEFGX0FQUExFVEFMSykKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIC1FSU5WQUw7Ci0gICAgICAgICAgICAgICAgICAgICAgICBpZiAoIWF0aWYpCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiAtRUFERFJOT1RBVkFJTDsKKwkJCQlyZXR1cm4gLUVQRVJNOworCQkJaWYgKHNhLT5zYXRfZmFtaWx5ICE9IEFGX0FQUExFVEFMSykKKwkJCQlyZXR1cm4gLUVJTlZBTDsKKwkJCWlmICghYXRpZikKKwkJCQlyZXR1cm4gLUVBRERSTk9UQVZBSUw7CiAKLSAgICAgICAgICAgICAgICAgICAgICAgIC8qCi0gICAgICAgICAgICAgICAgICAgICAgICAgKiBmb3Igbm93LCB3ZSBvbmx5IHN1cHBvcnQgcHJveHkgQUFSUCBvbiBFTEFQOwotICAgICAgICAgICAgICAgICAgICAgICAgICogd2Ugc2hvdWxkIGJlIGFibGUgdG8gZG8gaXQgZm9yIExvY2FsVGFsaywgdG9vLgotICAgICAgICAgICAgICAgICAgICAgICAgICovCi0gICAgICAgICAgICAgICAgICAgICAgICBpZiAoZGV2LT50eXBlICE9IEFSUEhSRF9FVEhFUikKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIC1FUFJPVE9OT1NVUFBPUlQ7CisJCQkvKgorCQkJICogZm9yIG5vdywgd2Ugb25seSBzdXBwb3J0IHByb3h5IEFBUlAgb24gRUxBUDsKKwkJCSAqIHdlIHNob3VsZCBiZSBhYmxlIHRvIGRvIGl0IGZvciBMb2NhbFRhbGssIHRvby4KKwkJCSAqLworCQkJaWYgKGRldi0+dHlwZSAhPSBBUlBIUkRfRVRIRVIpCisJCQkJcmV0dXJuIC1FUFJPVE9OT1NVUFBPUlQ7CiAKLSAgICAgICAgICAgICAgICAgICAgICAgIC8qCi0gICAgICAgICAgICAgICAgICAgICAgICAgKiBhdGlmIHBvaW50cyB0byB0aGUgY3VycmVudCBpbnRlcmZhY2Ugb24gdGhpcyBuZXR3b3JrOwotICAgICAgICAgICAgICAgICAgICAgICAgICogd2UgYXJlbid0IGNvbmNlcm5lZCBhYm91dCBpdHMgY3VycmVudCBzdGF0dXMgKGF0CisJCQkvKgorCQkJICogYXRpZiBwb2ludHMgdG8gdGhlIGN1cnJlbnQgaW50ZXJmYWNlIG9uIHRoaXMgbmV0d29yazsKKwkJCSAqIHdlIGFyZW4ndCBjb25jZXJuZWQgYWJvdXQgaXRzIGN1cnJlbnQgc3RhdHVzIChhdAogCQkJICogbGVhc3QgZm9yIG5vdyksIGJ1dCBpdCBoYXMgYWxsIHRoZSBzZXR0aW5ncyBhYm91dAogCQkJICogdGhlIG5ldHdvcmsgd2UncmUgZ29pbmcgdG8gcHJvYmUuIENvbnNlcXVlbnRseSwgaXQKIAkJCSAqIG11c3QgZXhpc3QuCi0gICAgICAgICAgICAgICAgICAgICAgICAgKi8KLSAgICAgICAgICAgICAgICAgICAgICAgIGlmICghYXRpZikKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIC1FQUREUk5PVEFWQUlMOworCQkJICovCisJCQlpZiAoIWF0aWYpCisJCQkJcmV0dXJuIC1FQUREUk5PVEFWQUlMOwogCi0gICAgICAgICAgICAgICAgICAgICAgICBuciA9IChzdHJ1Y3QgYXRhbGtfbmV0cmFuZ2UgKikmKGF0aWYtPm5ldHMpOwotICAgICAgICAgICAgICAgICAgICAgICAgLyoKLSAgICAgICAgICAgICAgICAgICAgICAgICAqIFBoYXNlIDEgaXMgZmluZSBvbiBMb2NhbHRhbGsgYnV0IHdlIGRvbid0IGRvCi0gICAgICAgICAgICAgICAgICAgICAgICAgKiBFdGhlcnRhbGsgcGhhc2UgMS4gQW55b25lIHdhbnRpbmcgdG8gYWRkIGl0IGdvIGFoZWFkLgotICAgICAgICAgICAgICAgICAgICAgICAgICovCi0gICAgICAgICAgICAgICAgICAgICAgICBpZiAoZGV2LT50eXBlID09IEFSUEhSRF9FVEhFUiAmJiBuci0+bnJfcGhhc2UgIT0gMikKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIC1FUFJPVE9OT1NVUFBPUlQ7Ci0KLSAgICAgICAgICAgICAgICAgICAgICAgIGlmIChzYS0+c2F0X2FkZHIuc19ub2RlID09IEFUQUREUl9CQ0FTVCB8fAotCQkJICAgIHNhLT5zYXRfYWRkci5zX25vZGUgPT0gMjU0KQotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gLUVJTlZBTDsKLQotICAgICAgICAgICAgICAgICAgICAgICAgLyoKLSAgICAgICAgICAgICAgICAgICAgICAgICAqIENoZWNrIGlmIHRoZSBjaG9zZW4gYWRkcmVzcyBpcyB1c2VkLiBJZiBzbyB3ZQotICAgICAgICAgICAgICAgICAgICAgICAgICogZXJyb3IgYW5kIEFUQ1Agd2lsbCB0cnkgYW5vdGhlci4KLSAgICAgICAgICAgICAgICAgICAgICAgICAqLwotICAgICAgICAgICAgICAgICAgICAgIAlpZiAoYXRpZl9wcm94eV9wcm9iZV9kZXZpY2UoYXRpZiwgJihzYS0+c2F0X2FkZHIpKSA8IDApCi0gICAgICAgICAgICAgICAgICAgICAgCQlyZXR1cm4gLUVBRERSSU5VU0U7Ci0gICAgICAgICAgICAgICAgICAgICAgCQorCQkJbnIgPSAoc3RydWN0IGF0YWxrX25ldHJhbmdlICopJihhdGlmLT5uZXRzKTsKIAkJCS8qCi0gICAgICAgICAgICAgICAgICAgICAgICAgKiBXZSBub3cgaGF2ZSBhbiBhZGRyZXNzIG9uIHRoZSBsb2NhbCBuZXR3b3JrLCBhbmQKKwkJCSAqIFBoYXNlIDEgaXMgZmluZSBvbiBMb2NhbHRhbGsgYnV0IHdlIGRvbid0IGRvCisJCQkgKiBFdGhlcnRhbGsgcGhh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RfQURNSU4pKQotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gLUVQRVJNOwotICAgICAgICAgICAgICAgICAgICAgICAgaWYgKHNhLT5zYXRfZmFtaWx5ICE9IEFGX0FQUExFVEFMSykKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIC1FSU5WQUw7Ci0gICAgICAgICAgICAgICAgICAgICAgICBpZiAoIWF0aWYpCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiAtRUFERFJOT1RBVkFJTDsKKwkJY2FzZSBTSU9DREFSUDoKKwkJCWlmICghY2FwYWJsZShDQVBfTkVUX0FETUlOKSkKKwkJCQlyZXR1cm4gLUVQRVJNOworCQkJaWYgKHNhLT5zYXRfZmFtaWx5ICE9IEFGX0FQUExFVEFMSykKKwkJCQlyZXR1cm4gLUVJTlZBTDsKKwkJCWlmICghYXRpZikKKwkJCQlyZXR1cm4gLUVBRERSTk9UQVZBSUw7CiAKLSAgICAgICAgICAgICAgICAgICAgICAgIC8qIGdpdmUgdG8gYWFycCBtb2R1bGUgdG8gcmVtb3ZlIHByb3h5IGVudHJ5ICovCi0gICAgICAgICAgICAgICAgICAgICAgICBhYXJwX3Byb3h5X3JlbW92ZShhdGlmLT5kZXYsICYoc2EtPnNhdF9hZGRyKSk7Ci0gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gMDsKKwkJCS8qIGdpdmUgdG8gYWFycCBtb2R1bGUgdG8gcmVtb3ZlIHByb3h5IGVudHJ5ICovCisJCQlhYXJwX3Byb3h5X3JlbW92ZShhdGlmLT5kZXYsICYoc2EtPnNhdF9hZGRyKSk7CisJCQlyZXR1cm4gMDsKIAl9CiAKIAlyZXR1cm4gY29weV90b191c2VyKGFyZywgJmF0cmVxLCBzaXplb2YoYXRyZXEpKSA/IC1FRkFVTFQgOiAwOwpAQCAtODk5LDcgKzg5OSw3IEBACiAJCQkJZGV2ID0gX19kZXZfZ2V0X2J5X25hb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X2JlMzIgZHN0X2lwLCBzdHJ1Y3QgbXBvYV9jbGllbnQgKmNsaWVudCk7CisJaW5fY2FjaGVfZW50cnkgKigqZ2V0X3dpdGhfbWFzaykoX19iZTMyIGRzdF9pcCwKIAkJCQkJIHN0cnVjdCBtcG9hX2NsaWVudCAqY2xpZW50LAogCQkJCQkgX19iZTMyIG1hc2spOwotICAgICAgICBpbl9jYWNoZV9lbnRyeSAqKCpnZXRfYnlfdmNjKShzdHJ1Y3QgYXRtX3ZjYyAqdmNjLCAKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc3RydWN0IG1wb2FfY2xpZW50ICpjbGllbnQpOwotICAgICAgICB2b2lkICAgICAgICAgICAgKCpwdXQpKGluX2NhY2hlX2VudHJ5ICplbnRyeSk7Ci0gICAgICAgIHZvaWQgICAgICAgICAgICAoKnJlbW92ZV9lbnRyeSkoaW5fY2FjaGVfZW50cnkgKmRlbEVudHJ5LAorCWluX2NhY2hlX2VudHJ5ICooKmdldF9ieV92Y2MpKHN0cnVjdCBhdG1fdmNjICp2Y2MsCisJCQkJICAgICAgc3RydWN0IG1wb2FfY2xpZW50ICpjbGllbnQpOworCXZvaWQgICAgICAgICAgICAoKnB1dCkoaW5fY2FjaGVfZW50cnkgKmVudHJ5KTsKKwl2b2lkICAgICAgICAgICAgKCpyZW1vdmVfZW50cnkpKGluX2NhY2hlX2VudHJ5ICpkZWxFbnRyeSwKIAkJCQkJc3RydWN0IG1wb2FfY2xpZW50ICpjbGllbnQgKTsKLSAgICAgICAgaW50ICAgICAgICAgICAgICgqY2FjaGVfaGl0KShpbl9jYWNoZV9lbnRyeSAqZW50cnksCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc3RydWN0IG1wb2FfY2xpZW50ICpjbGllbnQpOwotICAgICAgICB2b2lkICAgICAgICAgICAgKCpjbGVhcl9jb3VudCkoc3RydWN0IG1wb2FfY2xpZW50ICpjbGllbnQpOwotICAgICAgICB2b2lkICAgICAgICAgICAgKCpjaGVja19yZXNvbHZpbmcpKHN0cnVjdCBtcG9hX2NsaWVudCAqY2xpZW50KTsKLSAgICAgICAgdm9pZCAgICAgICAgICAgICgqcmVmcmVzaCkoc3RydWN0IG1wb2FfY2xpZW50ICpjbGllbnQpOwotICAgICAgICB2b2lkICAgICAgICAgICAgKCpkZXN0cm95X2NhY2hlKShzdHJ1Y3QgbXBvYV9jbGllbnQgKm1wYyk7CisJaW50ICAgICAgICAgICAgICgqY2FjaGVfaGl0KShpbl9jYWNoZV9lbnRyeSAqZW50cnksCisJCQkJICAgICBzdHJ1Y3QgbXBvYV9jbGllbnQgKmNsaWVudCk7CisJdm9pZCAgICAgICAgICAgICgqY2xlYXJfY291bnQpKHN0cnVjdCBtcG9hX2NsaWVudCAqY2xpZW50KTsKKwl2b2lkICAgICAgICAgICAgKCpjaGVja19yZXNvbHZpbmcpKHN0cnVjdCBtcG9hX2NsaWVudCAqY2xpZW50KTsKKwl2b2lkICAgICAgICAgICAgKCpyZWZyZXNoKShzdHJ1Y3QgbXBvYV9jbGllbnQgKmNsaWVudCk7CisJdm9pZCAgICAgICAgICAgICgqZGVzdHJveV9jYWNoZSkoc3RydWN0IG1wb2FfY2xpZW50ICptcGMpOwogfTsKIAogdHlwZWRlZiBzdHJ1Y3QgZWdfY2FjaGVfZW50cnl7Ci0gICAgICAgIHN0cnVjdCAgICAgICAgICAgICAgIGVnX2NhY2hlX2VudHJ5ICpuZXh0OwotICAgICAgICBzdHJ1Y3QgICAgICAgICAgICAgICBlZ19jYWNoZV9lbnRyeSAqcHJldjsKLSAgICAgICAgc3RydWN0ICAgICAgICAgICAgICAgdGltZXZhbCAgdHY7Ci0gICAgICAgIHVpbnQ4X3QgICAgICAgICAgICAgIE1QU19jdHJsX0FUTV9hZGRyW0FUTV9FU0FfTEVOXTsKLSAgICAgICAgc3RydWN0IGF0bV92Y2MgICAgICAgKnNob3J0Y3V0OwotICAgICAgICB1aW50MzJfdCAgICAgICAgICAgICB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Aob3B0X3B0ciA9PSBvcHRfZW5kKQorCQkJCWdvdG8gb3V0X2ludmFsaWRfb3B0aW9uOwogCi0gICAgICAgICAgICAgICAgICAgICAgICBsZW4gPSAqb3B0X3B0cisrOwotICAgICAgICAgICAgICAgICAgICAgICAgaWYgKGxlbiA8IDMpCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGdvdG8gb3V0X2ludmFsaWRfb3B0aW9uOwotICAgICAgICAgICAgICAgICAgICAgICAgLyoKLSAgICAgICAgICAgICAgICAgICAgICAgICAqIFJlbW92ZSB0aGUgdHlwZSBhbmQgbGVuIGZpZWxkcywgbGVhdmluZwotICAgICAgICAgICAgICAgICAgICAgICAgICoganVzdCB0aGUgdmFsdWUgc2l6ZQotICAgICAgICAgICAgICAgICAgICAgICAgICovCi0gICAgICAgICAgICAgICAgICAgICAgICBsZW4gICAgIC09IDI7Ci0gICAgICAgICAgICAgICAgICAgICAgICB2YWx1ZSAgID0gb3B0X3B0cjsKLSAgICAgICAgICAgICAgICAgICAgICAgIG9wdF9wdHIgKz0gbGVuOworCQkJbGVuID0gKm9wdF9wdHIrKzsKKwkJCWlmIChsZW4gPCAzKQorCQkJCWdvdG8gb3V0X2ludmFsaWRfb3B0aW9uOworCQkJLyoKKwkJCSAqIFJlbW92ZSB0aGUgdHlwZSBhbmQgbGVuIGZpZWxkcywgbGVhdmluZworCQkJICoganVzdCB0aGUgdmFsdWUgc2l6ZQorCQkJICovCisJCQlsZW4gICAgIC09IDI7CisJCQl2YWx1ZSAgID0gb3B0X3B0cjsKKwkJCW9wdF9wdHIgKz0gbGVuOwogCi0gICAgICAgICAgICAgICAgICAgICAgICBpZiAob3B0X3B0ciA+IG9wdF9lbmQpCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGdvdG8gb3V0X2ludmFsaWRfb3B0aW9uOwotICAgICAgICAgICAgICAgIH0KKwkJCWlmIChvcHRfcHRyID4gb3B0X2VuZCkKKwkJCQlnb3RvIG91dF9pbnZ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8KLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBBZGRlZCBzdXBwb3J0IGZvciBpbmNvbWluZyBjb25uZWN0aW9ucwotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNvIHdlIGNhbiBzdGFydCBkZXZlbG9waW5nIHNlcnZlciBhcHBzCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgb24gTGludXguCisJCQkJCUFkZGVkIHN1cHBvcnQgZm9yIGluY29taW5nIGNvbm5lY3Rpb25zCisJCQkJCXNvIHdlIGNhbiBzdGFydCBkZXZlbG9waW5nIHNlcnZlciBhcHBzCisJCQkJCW9uIExpbnV4LgogCQkJCQktCiAJCQkJCU1vZHVsZSBTdXBwb3J0CiBWZXJzaW9uIDAuMC40ICAgICAyLjEuMTA5ICAgMjEtanVsLTk4ICAgRWR1YXJkbyBNYXJjZWxvIFNlcnJhdAotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKGVtc2VycmF0QGdlb2NpdGllcy5jb20pCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBfCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgQWRkZWQgc3VwcG9ydCBmb3IgWDExUjYuNC4gTm93IHdlIGNhbiAKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB1c2UgREVDbmV0IHRyYW5zcG9ydCBmb3IgWCBvbiBMaW51eCEhIQotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLQorCQkJCSAgICAgICAoZW1zZXJyYXRAZ2VvY2l0aWVzLmNvbSkKKwkJCQkgICAgICAgXworCQkJCQlBZGRlZCBzdXBwb3J0IGZvciBYMTFSNi40LiBOb3cgd2UgY2FuCisJCQkJCXVzZSBERUNuZXQgdHJhbnNwb3J0IGZvciBYIG9uIExpbnV4ISEhCisJCQkJICAgICAgIC0KIFZlcnNpb24gMC4wLjUgICAgMi4xLjExMCAgIDAxLWF1Zy05OCAgIEVkdWFyZG8gTWFyY2VsbyBTZXJyYXQKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIChlbXNlcnJhdEBnZW9jaXRpZXMuY29tKQotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgUmVtb3ZlZCBidWdzIG9uIGZsb3cgY29udHJvbAotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgUmVtb3ZlZCBidWdzIG9uIGluY29taW5nIGFjY2Vzc2RhdGEKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIG9yZGVyCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAtCisJCQkJICAgICAgIChlbXNlcnJhdEBnZW9jaXRpZXMuY29tKQorCQkJCSAgICAgICBSZW1vdmVkIGJ1Z3Mgb24gZmxvdyBjb250cm9sCisJCQkJICAgICAgIFJlbW92ZWQgYnVncyBvbiBpbmNvbWluZyBhY2Nlc3NkYXRhCisJCQkJICAgICAgIG9yZGVyCisJCQkJICAgICAgIC0KIFZlcnNpb24gMC4wLjYgICAgMi4xLjExMCAgIDA3LWF1Zy05OCAgIEVkdWFyZG8gTWFyY2VsbyBTZXJyYXQKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGRuX3JlY3Ztc2cgZml4ZXMKKwkJCQkgICAgICAgZG5fcmVjdm1zZyBmaXhlcwogCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgUGF0cmljayBKLiBDYXVsZmllbGQKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGRuX2JpbmQgZml4ZXMKKwkJCQkJUGF0cmljayBKLiBDYXVsZmllbGQKKwkJCQkgICAgICAgZG5fYmluZCBmaXhlcwogKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioq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KwlpZiAodGIpCiAJCXJldHVybiB0Yi0+aW5zZXJ0KHRiLCByLCAoc3RydWN0IGRuX2tlcm5fcnRhICopcnRhLCBubGgsICZORVRMSU5LX0NCKHNrYikpOwogCiAJcmV0dXJuIC1FTk9CVUZTOwpAQCAtNjU0LDgwICs2NTQsODAgQEAKIAogc3RhdGljIGludCBkbl9maWJfc3luY19kb3duKF9fbGUxNiBsb2NhbCwgc3RydWN0IG5ldF9kZXZpY2UgKmRldiwgaW50IGZvcmNlKQogewotICAgICAgICBpbnQgcmV0ID0gMDsKLSAgICAgICAgaW50IHNjb3BlID0gUlRfU0NPUEVfTk9XSEVSRTsKKwlpbnQgcmV0ID0gMDsKKwlpbnQgc2NvcGUgPSBSVF9TQ09QRV9OT1dIRVJFOwogCi0gICAgICAgIGlmIChmb3JjZSkKLSAgICAgICAgICAgICAgICBzY29wZSA9IC0xOworCWlmIChmb3JjZSkKKwkJc2NvcGUgPSAtMTsKIAotICAgICAgICBmb3JfZmliX2luZm8oKSB7Ci0gICAgICAgICAgICAgICAgLyogCi0gICAgICAgICAgICAgICAgICogVGhpcyBtYWtlcyBubyBzZW5zZSBmb3IgREVDbmV0Li4uLiB3ZSB3aWxsIGFsbW9zdAotICAgICAgICAgICAgICAgICAqIGNlcnRhaW5seSBoYXZlIG1vcmUgdGhhbiBvbmUgbG9jYWwgYWRkcmVzcyB0aGUgc2FtZQotICAgICAgICAgICAgICAgICAqIG92ZXIgYWxsIG91ciBpbnRlcmZhY2VzLiBJdCBuZWVkcyB0aGlua2luZyBhYm91dAotICAgICAgICAgICAgICAgICAqIHNvbWUgbW9yZS4KLSAgICAgICAgICAgICAgICAgKi8KLSAgICAgICAgICAgICAgICBpZiAobG9jYWwgJiYgZmktPmZpYl9wcmVmc3JjID09IGxvY2FsKSB7Ci0gICAgICAgICAgICAgICAgICAgICAgICBmaS0+ZmliX2ZsYWdzIHw9IFJUTkhfRl9ERUFEOwotICAgICAgICAgICAgICAgICAgICAgICAgcmV0Kys7Ci0gICAgICAgICAgICAgICAgfSBlbHNlIGlmIChkZXYgJiYgZmktPmZpYl9uaHMpIHsKLSAgICAgICAgICAgICAgICAgICAgICAgIGludCBkZWFkID0gMDsKKwlmb3JfZmliX2luZm8oKSB7CisJCS8qCisJCSAqIFRoaXMgbWFrZXMgbm8gc2Vuc2UgZm9yIERFQ25ldC4uLi4gd2Ugd2lsbCBhbG1vc3QKKwkJICogY2VydGFpbmx5IGhhdmUgbW9yZSB0aGFuIG9uZSBsb2NhbCBhZGRyZXNzIHRoZSBzYW1lCisJCSAqIG92ZXIgYWxsIG91ciBpbnRlcmZhY2VzLiBJdCBuZWVkcyB0aGlua2luZyBhYm91dAorCQkgKiBzb21lIG1vcmUuCisJCSAqLworCQlpZiAobG9jYWwgJiYgZmktPmZpYl9wcmVmc3JjID09IGxvY2FsKSB7CisJCQlmaS0+ZmliX2ZsYWdzIHw9IFJUTkhfRl9ERUFEOworCQkJcmV0Kys7CisJCX0gZWxzZSBpZiAoZGV2ICYmIGZpLT5maWJfbmhzKSB7CisJCQlpbnQgZGVhZCA9IDA7CiAKLSAgICAgICAgICAgICAgICAgICAgICAgIGNoYW5nZV9uZXh0aG9wcyhmaSkgewotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAobmgtPm5oX2ZsYWdzJlJUTkhfRl9ERUFEKQotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGRlYWQrKzsKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZWxzZSBpZiAobmgtPm5oX2RldiA9PSBkZXYgJiYKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIG5oLT5uaF9zY29wZSAhPSBzY29wZSkgeworCQkJY2hhbmdlX25leHRob3BzKGZpKSB7CisJCQkJaWYgKG5oLT5uaF9mbGFncyZSVE5IX0ZfREVBRCkKKwkJCQkJZGVhZCsrOworCQkJCWVsc2UgaWYgKG5oLT5uaF9kZXYgPT0gZGV2ICYmCisJCQkJCQluaC0+bmhfc2NvcGUgIT0gc2NvcGUpIHsKIAkJCQkJc3Bpbl9sb2NrX2JoKCZkbl9maWJfbXVsdGlwYXRoX2xvY2spOwotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIG5oLT5uaF9mbGFncyB8PSBSVE5IX0ZfREVBRDsKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBmaS0+ZmliX3Bvd2VyIC09IG5oLT5uaF9wb3dlcjsKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBuaC0+bmhfcG93ZXIgPSAwOworCQkJCQluaC0+bmhfZmxhZ3MgfD0gUlROSF9GX0RFQUQ7CisJCQkJCWZpLT5maWJfcG93ZXIgLT0gbmgtPm5oX3Bvd2VyOworCQkJCQluaC0+bmhfcG93ZXIgPSAwOwogCQkJCQlzcGluX3VubG9ja19iaCgmZG5fZmliX211bHRpcGF0aF9sb2NrKTsKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBkZWFkKys7Ci0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0KLSAgICAgICAgICAgICAgICAgICAgICAgIH0gZW5kZm9yX25leHRob3BzKGZpKQotICAgICAgICAgICAgICAgICAgICAgICAgaWYgKGRlYWQgPT0gZmktPmZpYl9uaHMpIHsKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZmktPmZpYl9mbGFncyB8PSBSVE5IX0ZfREVBRDsKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0Kys7Ci0gICAgICAgICAgICAgICAgICAgICAgICB9Ci0gICAgICAgICAgICAgICAgfQotICAgICAgICB9IGVuZGZvcl9maWJfaW5mbygpOwotICAgICAgICByZXR1cm4gcmV0OworCQkJCQlkZWFkKys7CisJCQkJfQorCQkJfSBlbmRmb3JfbmV4dGhvcHMoZmkpCisJCQlpZiAoZGVhZCA9PSBmaS0+ZmliX25ocykgeworCQkJCWZpLT5maWJfZmxhZ3MgfD0gUlROSF9GX0RFQUQ7CisJCQkJcmV0Kys7CisJCQl9CisJCX0KKwl9IGVuZGZvcl9maWJfaW5mbygpOworCXJldHVybiByZXQ7CiB9CiAKIAogc3RhdGljIGludCBkbl9maWJfc3luY191cChzdHJ1Y3QgbmV0X2RldmljZSAqZGV2KQogewotICAgICAgICBpbnQgcmV0ID0gMDsKKwlpbnQgcmV0ID0gMDsKIAotICAgICAgICBpZiAoIShkZXYtPmZsYWdzJklGRl9VUCkpCi0gICAgICAgICAgICAgICAgcmV0dXJuIDA7CisJaWYgKCEoZGV2LT5mbGFncyZJRkZfVVApKQorCQlyZXR1cm4gMDsKIAotICAgICAgICBmb3JfZmliX2luZm8oKSB7Ci0gICAgICAgICAgICAgICAgaW50IGFsaXZlID0gMDsKKwlmb3JfZmliX2luZm8oKSB7CisJCWludCBhbGl2ZSA9IDA7CiAKLSAgICAgICAgICAgICAgICBjaGFuZ2VfbmV4dGhvcHMoZmkpIHsKLSAgICAgICAgICAgICAgICAgICAgICAgIGlmICghKG5oLT5uaF9mbGFncyZSVE5IX0ZfREVBRCkpIHsKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgYWxpdmUrKzsKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY29udGludWU7Ci0gICAgICAgICAgICAgICAgICAgICAgICB9Ci0gICAgICAgICAgICAgICAgICAgICAgICBpZiAobmgtPm5oX2RldiA9PSBOVUxMIHx8ICEobmgtPm5oX2Rldi0+ZmxhZ3MmSUZGX1VQKSkKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY29udGludWU7Ci0gICAgICAgICAgICAgICAgICAgICAgICBpZiAobmgtPm5oX2RldiAhPSBkZXYgfHwgZGV2LT5kbl9wdHIgPT0gTlVMTCkKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY29udGludWU7Ci0gICAgICAgICAgICAgICAgICAgICAgICBhbGl2ZSsrOwor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ZpYl9pbmZvKCk7CisJcmV0dXJuIHJldDsKIH0KIAogc3RhdGljIHN0cnVjdCBub3RpZmllcl9ibG9jayBkbl9maWJfZG5hZGRyX25vdGlmaWVyID0gewpkaWZmIC0tZ2l0IGEvbmV0L2RlY25ldC9kbl9uZWlnaC5jIGIvbmV0L2RlY25ldC9kbl9uZWlnaC5jCmluZGV4IDczMjJiYjMuLmJmNzAxY2YgMTAwNjQ0Ci0tLSBhL25ldC9kZWNuZXQvZG5fbmVpZ2guYworKysgYi9uZXQvZGVjbmV0L2RuX25laWdoLmMKQEAgLTMsNyArMyw3IEBACiAgKiAgICAgICAgICAgICAgb3BlcmF0aW5nIHN5c3RlbS4gIERFQ25ldCBpcyBpbXBsZW1lbnRlZCB1c2luZyB0aGUgIEJTRCBTb2NrZXQKICAqICAgICAgICAgICAgICBpbnRlcmZhY2UgYXMgdGhlIG1lYW5zIG9mIGNvbW11bmljYXRpb24gd2l0aCB0aGUgdXNlciBsZXZlbC4KICAqCi0gKiAgICAgICAgICAgICAgREVDbmV0IE5laWdoYm91ciBGdW5jdGlvbnMgKEFkamFjZW5jeSBEYXRhYmFzZSBhbmQgCisgKiAgICAgICAgICAgICAgREVDbmV0IE5laWdoYm91ciBGdW5jdGlvbnMgKEFkamFjZW5jeSBEYXRhYmFzZSBhbmQKICAqICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBPbi1FdGhlcm5ldCBDYWNoZSkKICAqCiAgKiBBdXRob3I6ICAgICAgU3RldmUgV2hpdGVob3VzZSA8U3RldmVXQEFDTS5vcmc+CkBAIC0yNzcsMTkgKzI3NywxOSBAQAogCXN0cnVjdCBkbl9za2JfY2IgKmNiID0gRE5fU0tCX0NCKHNrYik7CiAKIAotICAgICAgICBpZiAoc2tiX2hlYWRyb29tKHNrYikgPCBoZWFkcm9vbSkgewotICAgICAgICAgICAgICAgIHN0cnVjdCBza19idWZmICpza2IyID0gc2tiX3JlYWxsb2NfaGVhZHJvb20oc2tiLCBoZWFkcm9vbSk7Ci0gICAgICAgICAgICAgICAgaWYgKHNrYjIgPT0gTlVMTCkgeworCWlmIChza2JfaGVhZHJvb20oc2tiKSA8IGhlYWRyb29tKSB7CisJCXN0cnVjdCBza19idWZmICpza2IyID0gc2tiX3JlYWxsb2NfaGVhZHJvb20oc2tiLCBoZWFkcm9vbSk7CisJCWlmIChza2IyID09IE5VTEwpIHsKIAkJCWlmIChuZXRfcmF0ZWxpbWl0KCkpCi0gICAgICAgICAgICAgICAgICAgICAgICAJcHJpbnRrKEtFUk5fQ1JJVCAiZG5fc2hvcnRfb3V0cHV0OiBubyBtZW1vcnlcbiIpOwotICAgICAgICAgICAgICAgICAgICAgICAga2ZyZWVfc2tiKHNrYik7Ci0gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gLUVOT0JVRlM7Ci0gICAgICAgICAgICAgICAgfQotICAgICAgICAgICAgICAgIGtmcmVlX3NrYihza2IpOwotICAgICAgICAgICAgICAgIHNrYiA9IHNrYjI7CisJCQkJcHJpbnRrKEtFUk5fQ1JJVCAiZG5fc2hvcnRfb3V0cHV0OiBubyBtZW1vcnlcbiIpOworCQkJa2ZyZWVfc2tiKHNrYik7CisJCQlyZXR1cm4gLUVOT0JVRlM7CisJCX0KKwkJa2ZyZWVfc2tiKHNrYik7CisJCXNrYiA9IHNrYjI7CiAJCWlmIChuZXRfcmF0ZWxpbWl0KCkpCi0gICAgICAgICAgICAgICAgCXByaW50ayhLRVJOX0lORk8gImRuX3Nob3J0X291dHB1dDogSW5jcmVhc2luZyBoZWFkcm9vbVxuIik7Ci0gICAgICAgIH0KKwkJCXByaW50ayhLRVJOX0lORk8gImRuX3Nob3J0X291dHB1dDogSW5jcmVhc2luZyBoZWFkcm9vbVxuIik7CisJfQogCiAJZGF0YSA9IHNrYl9wdXNoKHNrYiwgc2l6ZW9mKHN0cnVjdCBkbl9zaG9ydF9wYWNrZXQpICsgMik7CiAJKigoX19sZTE2ICopZGF0YS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ICAgICAgICAgaWYgKHNrYl90YWlscm9vbShza2IpIDwgUlRBX0FMSUdOKFJUQV9BTElHTihzaXplb2YoKm5ocCkpICsgNCkpCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGdvdG8gcnRhdHRyX2ZhaWx1cmU7Ci0gICAgICAgICAgICAgICAgICAgICAgICBuaHAgPSAoc3RydWN0IHJ0bmV4dGhvcCAqKXNrYl9wdXQoc2tiLCBSVEFfQUxJR04oc2l6ZW9mKCpuaHApKSk7Ci0gICAgICAgICAgICAgICAgICAgICAgICBuaHAtPnJ0bmhfZmxhZ3MgPSBuaC0+bmhfZmxhZ3MgJiAweEZGOwotICAgICAgICAgICAgICAgICAgICAgICAgbmhwLT5ydG5oX2hvcHMgPSBuaC0+bmhfd2VpZ2h0IC0gMTsKLSAgICAgICAgICAgICAgICAgICAgICAgIG5ocC0+cnRuaF9pZmluZGV4ID0gbmgtPm5oX29pZjsKLSAgICAgICAgICAgICAgICAgICAgICAgIGlmIChuaC0+bmhfZ3cpCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFJUQV9QVVQoc2tiLCBSVEFfR0FURVdBWSwgMiwgJm5oLT5uaF9ndyk7Ci0gICAgICAgICAgICAgICAgICAgICAgICBuaHAtPnJ0bmhfbGVuID0gc2tiLT50YWlsIC0gKHVuc2lnbmVkIGNoYXIgKiluaHA7Ci0gICAgICAgICAgICAgICAgfSBlbmRmb3JfbmV4dGhvcHMoZmkpOwotICAgICAgICAgICAgICAgIG1wX2hlYWQtPnJ0YV90eXBlID0gUlRBX01VTFRJUEFUSDsKLSAgICAgICAgICAgICAgICBtcF9oZWFkLT5ydGFfbGVuID0gc2tiLT50YWlsIC0gKHU4KiltcF9oZWFkOwotICAgICAgICB9CisJCWZvcl9uZXh0aG9wcyhmaSkgeworCQkJaWYgKHNrYl90YWlscm9vbShza2IpIDwgUlRBX0FMSUdOKFJUQV9BTElHTihzaXplb2YoKm5ocCkpICsgNCkpCisJCQkJZ290byB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MVF9ERVZJQ0UsCi0JCS5wcm9jbmFtZSA9ICJkZWZhdWx0X2RldmljZSIsIAotCQkubWF4bGVuID0gMTYsIAorCQkucHJvY25hbWUgPSAiZGVmYXVsdF9kZXZpY2UiLAorCQkubWF4bGVuID0gMTYsCiAJCS5tb2RlID0gMDY0NCwKIAkJLnByb2NfaGFuZGxlciA9IGRuX2RlZl9kZXZfaGFuZGxlciwKIAkJLnN0cmF0ZWd5ID0gZG5fZGVmX2Rldl9zdHJhdGVneSwKQEAgLTQzMiwzMiArNDMyLDMyIEBACiAJCS5leHRyYTIgPSAmbWF4X2RlY25ldF9ub19mY19tYXhfY3duZAogCX0sCiAgICAgICAgewotICAgICAgICAgICAgICAgIC5jdGxfbmFtZSA9IE5FVF9ERUNORVRfTUVNLAotICAgICAgICAgICAgICAgIC5wcm9jbmFtZSA9ICJkZWNuZXRfbWVtIiwKLSAgICAgICAgICAgICAgICAuZGF0YSA9ICZzeXNjdGxfZGVjbmV0X21lbSwKLSAgICAgICAgICAgICAgICAubWF4bGVuID0gc2l6ZW9mKHN5c2N0bF9kZWNuZXRfbWVtKSwKLSAgICAgICAgICAgICAgICAubW9kZSA9IDA2NDQsCi0gICAgICAgICAgICAgICAgLnByb2NfaGFuZGxlciA9ICZwcm9jX2RvaW50dmVjLAotICAgICAgICAgICAgICAgIC5zdHJhdGVneSA9ICZzeXNjdGxfaW50dmVjLAotICAgICAgICB9LAotICAgICAgICB7Ci0gICAgICAgICAgICAgICAgLmN0bF9uYW1lID0gTkVUX0RFQ05FVF9STUVNLAotICAgICAgICAgICAgICAgIC5wcm9jbmFtZSA9ICJkZWNuZXRfcm1lbSIsCi0gICAgICAgICAgICAgICAgLmRhdGEgPSAmc3lzY3RsX2RlY25ldF9ybWVtLAotICAgICAgICAgICAgICAgIC5tYXhsZW4gPSBzaXplb2Yoc3lzY3RsX2RlY25ldF9ybWVtKSwKLSAgICAgICAgICAgICAgICAubW9kZSA9IDA2NDQsCi0gICAgICAgICAgICAgICAgLnByb2NfaGFuZGxlciA9ICZwcm9jX2RvaW50dmVjLAotICAgICAgICAgICAgICAgIC5zdHJhdGVneSA9ICZzeXNjdGxfaW50dmVjLAotICAgICAgICB9LAotICAgICAgICB7Ci0gICAgICAgICAgICAgICAgLmN0bF9uYW1lID0gTkVUX0RFQ05FVF9XTUVNLAotICAgICAgICAgICAgICAgIC5wcm9jbmFtZSA9ICJkZWNuZXRfd21lbSIsCi0gICAgICAgICAgICAgICAgLmRhdGEgPSAmc3lzY3RsX2RlY25ldF93bWVtLAotICAgICAgICAgICAgICAgIC5tYXhsZW4gPSBzaXplb2Yoc3lzY3RsX2RlY25ldF93bWVtKSwKLSAgICAgICAgICAgICAgICAubW9kZSA9IDA2NDQsCi0gICAgICAgICAgICAgICAgLnByb2NfaGFuZGxlciA9ICZwcm9jX2RvaW50dmVjLAotICAgICAgICAgICAgICAgIC5zdHJhdGVneSA9ICZzeXNjdGxfaW50dmVjLAotICAgICAgICB9LAorCQkuY3RsX25hbWUgPSBORVRfREVDTkVUX01FTSwKKwkJLnByb2NuYW1lID0gImRlY25ldF9tZW0iLAorCQkuZGF0YSA9ICZzeXNjdGxfZGVjbmV0X21lbSwKKwkJLm1heGxlbiA9IHNpemVvZihzeXNjdGxfZGVjbmV0X21lbSksCisJCS5tb2RlID0gMDY0NCwKKwkJLnByb2NfaGFuZGxlciA9ICZwcm9jX2RvaW50dmVjLAorCQkuc3RyYXRlZ3kgPSAmc3lzY3RsX2ludHZlYywKKwl9LAorCXsKKwkJLmN0bF9uYW1lID0gTkVUX0RFQ05FVF9STUVNLAorCQkucHJvY25hbWUgPSAiZGVjbmV0X3JtZW0iLAorCQkuZGF0YSA9ICZzeXNjdGxfZGVjbmV0X3JtZW0sCisJCS5tYXhsZW4gPSBzaXplb2Yoc3lzY3RsX2RlY25ldF9ybWVtKSwKKwkJLm1vZGUgPSAwNjQ0LAorCQkucHJvY19oYW5kbGVyID0gJnByb2NfZG9pbnR2ZWMsCisJCS5zdHJhdGV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lkKQogewogCS8qIFRoaXMgaXMgY29tbW9uIHdpdGggMmFkZHIsIHNvIHVzZSB0aGF0IGluc3RlYWQgKi8KLQlpZWVlODAyMTFzb2Z0bWFjX2hkcl8yYWRkcihtYWMsIChzdHJ1Y3QgaWVlZTgwMjExX2hkcl8yYWRkciAqKWhlYWRlciwgdHlwZSwgZGVzdCk7CQotCQorCWllZWU4MDIxMXNvZnRtYWNfaGRyXzJhZGRyKG1hYywgKHN0cnVjdCBpZWVlODAyMTFfaGRyXzJhZGRyICopaGVhZGVyLCB0eXBlLCBkZXN0KTsKKwogCS8qIEZpbGwgaW4gdGhlIEJTUyBJRCAqLwogCWlmKGJzc2lkID09IE5VTEwpCiAJCW1lbXNldChoZWFkZXItPmFkZHIzLCAweEZGLCBFVEhfQUxFTik7CkBAIC0yMDEsMTEgKzIwMSwxMSBAQAogCiAvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioKICAqIENyZWF0ZSBNYW5hZ2VtZW50IHBhY2tldHMKLSAqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKi8gCisgKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiovCiAKIC8qIENyZWF0ZXMgYW4gYXNzb2NpYXRpb24gcmVxdWVzdCBwYWNrZXQgKi8KIHN0YXRpYyB1MzIKLWllZWU4MDIxMXNvZnRtYWNfYXNzb2NfcmVxKHN0cnVjdCBpZWVlODAyMTFfYXNzb2NfcmVxdWVzdCAqKnBrdCwgCitpZWVlODAyMTFzb2Z0bWFjX2Fzc29jX3JlcShzdHJ1Y3QgaWVlZTgwMjExX2Fzc29jX3JlcXVlc3QgKipwa3QsCiAJc3RydWN0IGllZWU4MDIxMXNvZnRtYWNfZGV2aWNlICptYWMsI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gICAgICAgfSwKKwl9LAogCi0gICAgICAgIHsKLSAgICAgICAgICAgICAgICAudHlwZSA9ICAgICAgIFNPQ0tfREdSQU0sCi0gICAgICAgICAgICAgICAgLnByb3RvY29sID0gICBJUFBST1RPX1VEUCwKLSAgICAgICAgICAgICAgICAucHJvdCA9ICAgICAgICZ1ZHBfcHJvdCwKLSAgICAgICAgICAgICAgICAub3BzID0gICAgICAgICZpbmV0X2RncmFtX29wcywKLSAgICAgICAgICAgICAgICAuY2FwYWJpbGl0eSA9IC0xLAotICAgICAgICAgICAgICAgIC5ub19jaGVjayA9ICAgVURQX0NTVU1fREVGQVVMVCwKLSAgICAgICAgICAgICAgICAuZmxhZ3MgPSAgICAgIElORVRfUFJPVE9TV19QRVJNQU5FTlQsCisJeworCQkudHlwZSA9ICAgICAgIFNPQ0tfREdSQU0sCisJCS5wcm90b2NvbCA9ICAgSVBQUk9UT19VRFAsCisJCS5wcm90ID0gICAgICAgJnVkcF9wcm90LAorCQkub3BzID0gICAgICAgICZpbmV0X2RncmFtX29wcywKKwkJLmNhcGFiaWxpdHkgPSAtMSwKKwkJLm5vX2NoZWNrID0gICBVRFBfQ1NVTV9ERUZBVUxULAorCQkuZmxhZ3MgPSAgICAgIElORVRfUFJPVE9TV19QRVJNQU5FTlQsCiAgICAgICAgfSwKLSAgICAgICAgCisKIAogICAgICAgIHsKLSAgICAgICAgICAgICAgIC50eXBlID0gICAgICAgU09DS19SQVcsCi0gICAgICAgICAgICAgICAucHJvdG9jb2wgPSAgIElQUFJPVE9fSVAsCS8qIHdpbGQgY2FyZCAqLwotICAgICAgICAgICAgICAgLnByb3QgPSAgICAgICAmcmF3X3Byb3QsCi0gICAgICAgICAgICAgICAub3BzID0gICAgICAgICZpbmV0X3NvY2tyYXdfb3BzLAotICAgICAgICAgICAgICAgLmNhcGFiaWxpdHkgPSBDQVBfTkVUX1JBVywKLSAgICAgICAgICAgICAgIC5ub19jaGVjayA9ICAgVURQX0NTVU1fREVGQVVMVCwKLS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y3QgaXBfY29ubnRyYWNrX3R1cGxlICpydHVwbGUpCiB7CkBAIC05NDMsNyArOTQzLDcgQEAKIAogCWN0ID0gaXBfY29ubnRyYWNrX2FsbG9jKG90dXBsZSwgcnR1cGxlKTsKIAlpZiAoY3QgPT0gTlVMTCB8fCBJU19FUlIoY3QpKQotCQlyZXR1cm4gLUVOT01FTTsJCisJCXJldHVybiAtRU5PTUVNOwogCiAJaWYgKCFjZGFbQ1RBX1RJTUVPVVQtMV0pCiAJCWdvdG8gZXJyOwpAQCAtOTc5LDEzICs5NzksMTMgQEAKIAogCXJldHVybiAwOwogCi1lcnI6CQorZXJyOgogCWlwX2Nvbm50cmFja19mcmVlKGN0KTsKIAlyZXR1cm4gZXJyOwogfQogCi1zdGF0aWMgaW50IAotY3RuZXRsaW5rX25ld19jb25udHJhY2soc3RydWN0IHNvY2sgKmN0bmwsIHN0cnVjdCBza19idWZmICpza2IsIAorc3RhdGljIGludAorY3RuZXRsaW5rX25ld19jb25udHJhY2soc3RydWN0IHNvY2sgKmN0bmwsIHN0cnVjdCBza19idWZmICpza2IsCiAJCQlzdHJ1Y3Qgbmxtc2doZHIgKm5saCwgc3RydWN0IG5mYXR0ciAqY2RhW10sIGludCAqZXJycCkKIHsKIAlzdHJ1Y3QgaXBfY29ubnRyYWNrX3R1cGxlIG90dXBsZSwgcnR1cGxlOwpAQCAtMTAzOSw5ICsxMDM5LDkgQEAKIAlyZXR1cm4gZXJyOwogfQogCi0vKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiogCi0gKiBFWFBFQ1QgCi0gKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiovIAorLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqCisgKiBFWFBFQ1QKKyAqKioqKioqKio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AgICAgICAgICAgICB1bnNpZ25lZCBpbnQgKmNscywKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVuc2lnbmVkIGludCAqY29uLAotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdW5zaWduZWQgaW50ICp0YWcpCitzdGF0aWMgdW5zaWduZWQgY2hhciBhc24xX2lkX2RlY29kZShzdHJ1Y3QgYXNuMV9jdHggKmN0eCwKKwkJCQkgICAgdW5zaWduZWQgaW50ICpjbHMsCisJCQkJICAgIHVuc2lnbmVkIGludCAqY29uLAorCQkJCSAgICB1bnNpZ25lZCBpbnQgKnRhZykKIHsKIAl1bnNpZ25lZCBjaGFyIGNoOwotCQorCiAJaWYgKCFhc24xX29jdGV0X2RlY29kZShjdHgsICZjaCkpCiAJCXJldHVybiAwOwotCQkKKwogCSpjbHMgPSAoY2ggJiAweEMwKSA+PiA2OwogCSpjb24gPSAoY2ggJiAweDIwKSA+PiA1OwogCSp0YWcgPSAoY2ggJiAweDFGKTsKLQkKKwogCWlmICgqdGFnID09IDB4MUYpIHsKIAkJaWYgKCFhc24xX3RhZ19kZWNvZGUoY3R4LCB0YWcpKQogCQkJcmV0dXJuIDA7CkBAIC0yMDcsMjUgKzIwNywyNSBAQAogfQogCiBzdGF0aWMgdW5zaWduZWQgY2hhciBhc24xX2xlbmd0aF9kZWNvZGUoc3RydWN0IGFzbjFfY3R4ICpjdHgsCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdW5zaWduZWQgaW50ICpkZWYsCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdW5zaWduZWQgaW50ICpsZW4pCisJCQkJCXVuc2lnbmVkIGludCAqZGVmLAorCQkJCQl1bnNpZ25lZCBpbnQgKmxlbikKIHsKIAl1bnNpZ25lZCBjaGFyIGNoLCBjbnQ7Ci0JCisKIAlpZiAoIWFzbjFfb2N0ZXRfZGVjb2RlKGN0eCwgJmNoKSkKIAkJcmV0dXJuIDA7Ci0JCQorCiAJaWYgKGNoID09IDB4ODApCiAJCSpkZWYgPSAwOwogCWVsc2UgewogCQkqZGVmID0gMTsKLQkJCisKIAkJaWYgKGNoIDwgMHg4MCkKIAkJCSpsZW4gPSBjaDsKIAkJZWxzZSB7CiAJCQljbnQgPSAodW5zaWduZWQgY2hhcikgKGNoICYgMHg3Rik7CiAJCQkqbGVuID0gMDsKLQkJCQorCiAJCQl3aGlsZSAoY250ID4gMCkgewogCQkJCWlmICghYXNuMV9vY3RldF9kZWNvZGUoY3R4LCAmY2gpKQogCQkJCQlyZXR1cm4gMDsKQEAgLTIzOSwyMCArMjM5LDIwIEBACiB9CiAKIHN0YXRpYyB1bnNpZ25lZCBjaGFyIGFzbjFfaGVhZGVyX2RlY29kZShzdHJ1Y3QgYXNuMV9jdHggKmN0eCwKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB1bnNpZ25lZCBjaGFyICoqZW9jLAotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVuc2lnbmVkIGludCAqY2xzLAotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVuc2lnbmVkIGludCAqY29uLAotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVuc2lnbmVkIGludCAqdGFnKQorCQkJCQl1bnNpZ25lZCBjaGFyICoqZW9jLAorCQkJCQl1bnNpZ25lZCBpbnQgKmNscywKKwkJCQkJdW5zaWduZWQgaW50ICpjb24sCisJCQkJCXVuc2lnbmVkIGludCAqdGFnKQogewogCXVuc2lnbmVkIGludCBkZWYsIGxlbjsKLQkKKwogCWlmICghYXNuMV9pZF9kZWNvZGUoY3R4LCBjbHMsIGNvbiwgdGFnKSkKIAkJcmV0dXJuIDA7Ci0JCQorCiAJZGVmID0gbGVuID0gMDsKIAlpZiAoIWFzbjFfbGVuZ3RoX2RlY29kZShjdHgsICZkZWYsICZsZW4pKQogCQlyZXR1cm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WxlbiA9IHNwcmludGYoYnVmZmVyLAotCSAgICAgICAgICAgICAgIlBlZXIgUElEICAgICAgICAgIDogJWRcbiIKLQkgICAgICAgICAgICAgICJDb3B5IG1vZGUgICAgICAgICA6ICVodVxuIgotCSAgICAgICAgICAgICAgIkNvcHkgcmFuZ2UgICAgICAgIDogJXVcbiIKLQkgICAgICAgICAgICAgICJRdWV1ZSBsZW5ndGggICAgICA6ICV1XG4iCi0JICAgICAgICAgICAgICAiUXVldWUgbWF4LiBsZW5ndGggOiAldVxuIgorCQkgICAgICAiUGVlciBQSUQgICAgICAgICAgOiAlZFxuIgorCQkgICAgICAiQ29weSBtb2RlICAgICAgICAgOiAlaHVcbiIKKwkJICAgICAgIkNvcHkgcmFuZ2UgICAgICAgIDogJXVcbiIKKwkJICAgICAgIlF1ZXVlIGxlbmd0aCAgICAgIDogJXVcbiIKKwkJICAgICAgIlF1ZXVlIG1heC4gbGVuZ3RoIDogJXVcbiIKIAkJICAgICAgIlF1ZXVlIGRyb3BwZWQgICAgIDogJXVcbiIKIAkJICAgICAgIk5ldGxpbmsgZHJvcHBlZCAgIDogJXVcbiIsCi0JICAgICAgICAgICAgICBwZWVyX3BpZCwKLQkgICAgICAgICAgICAgIGNvcHlfbW9kZSwKLQkgICAgICAgICAgICAgIGNvcHlfcmFuZ2UsCi0JICAgICAgICAgICAgICBxdWV1ZV90b3RhbCwKLQkgICAgICAgICAgICAgIHF1ZXVlX21heGxlbiwKKwkJICAgICAgcGVlcl9waWQsCisJCSAgICAgIGNvcHlfbW9kZSwKKwkJICAgICAgY29weV9yYW5nZSwKKwkJICAgICAgcXVldWVfdG90YWwsCisJCSAgICAgIHF1ZXVlX21heGxlbiwKIAkJICAgICAgcXVldWVfZHJvcHBlZCwKIAkJICAgICAgcXVldWVfdXNlcl9kcm9wcGVkKTsKIAogCXJlYWRfdW5sb2NrX2JoKCZxdWV1ZV9sb2NrKTsKLQkKKwogCSpzdGFydCA9IGJ1ZmZlciArIG9mZnNldDsK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hsKGlwaC0+c2FkZHIpLCBzcG9ydCwKIAkJCQkgICAgICAgY29uZmlnLT5oYXNoX2luaXR2YWwpOwogCQlicmVhazsKIAljYXNlIENMVVNURVJJUF9IQVNITU9ERV9TSVBfU1BUX0RQVDoKQEAgLTI5NSw4ICsyOTcsOCBAQAogCXJldHVybiB0ZXN0X2JpdChoYXNoIC0gMSwgJmNvbmZpZy0+bG9jYWxfbm9kZXMpOwogfQogCi0vKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiogCi0gKiBJUFRBQkxFUyBUQVJHRVQgCisvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioKKyAqIElQVEFCTEVTIFRBUkdFVAogICoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqLwogCiBzdGF0aWMgdW5zaWduZWQgaW50CkBAIC0zMTksNyArMzIxLDcgQEAKIAlpZiAobWFyayA9PSBOVUxMKSB7CiAJCXByaW50ayhLRVJOX0VSUiAiQ0xVU1RFUklQOiBubyBjb25udHJhY2shXG4iKTsKIAkJCS8qIEZJWE1FOiBuZWVkIHRvIGRyb3AgaW52YWxpZCBvbmVzLCBzaW5jZSByZXBsaWVzCi0JCQkgKiB0byBvdXRnb2luZyBjb25uZWN0aW9ucyBvZiBvdGhlciBub2RlcyB3aWxsIGJlIAorCQkJICogdG8gb3V0Z29pbmcgY29ubmVjdGlvbnMgb2Ygb3RoZXIgbm9kZXMgd2lsbCBiZQogCQkJICogbWFya2VkIGFzIElOVkFMSUQgKi8KIAkJcmV0dXJuIE5GX0RST1A7CiAJfQpAQCAtMzI3LDExICszMjksMTEgQEAKIAkvKiBzcGVjaWFsIGNhc2U6IElDTVAgZXJyb3IgaGFuZGxpbmcuIGNvbm50cmFjayBkaXN0aW5ndWlzaGVzI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OwogCiAKLS8qKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiAKLSAqIEFSUCBNQU5HTElORyBDT0RFIAorLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqCisgKiBBUlAgTUFOR0xJTkcgQ09ERQogICoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqLwogCiAvKiBoYXJkY29kZWQgZm9yIDQ4Yml0IGV0aGVybmV0IGFuZCAzMmJpdCBpcHY0IGFkZHJlc3NlcyAqLwpAQCAtNDkzLDcgKzQ5Niw3IEBACiB9IF9fYXR0cmlidXRlX18gKChwYWNrZWQpKTsKIAogI2lmZGVmIENMVVNURVJJUF9ERUJVRwotc3RhdGljIHZvaWQgYXJwX3ByaW50KHN0cnVjdCBhcnBfcGF5bG9hZCAqcGF5bG9hZCkgCitzdGF0aWMgdm9pZCBhcnBfcHJpbnQoc3RydWN0IGFycF9wYXlsb2FkICpwYXlsb2FkKQogewogI2RlZmluZSBIQlVGRkVSTEVOIDMwCiAJY2hhciBoYnVmZmVyW0hCVUZGRVJMRU5dOwpAQCAtNTA3LDcgKzUxMCw3IEBACiAJfQogCWhidWZmZXJbLS1rXT0nXDAnOwogCi0JcHJpbnRrKCJzcmMgJXUuJXUuJXUuJXVAJXMsIGRzdCAldS4ldS4ldS4ldVxuIiwgCisJcHJpbnRrKCJzcmMgJXUuJXUuJXUuJXVAJXMsIGRzdCAldS4ldS4ldS4ldVxuIiwKIAkJTklQUVVBRChwYXlsb2FkLT5zcmNfaXApLCBoYnVmZmVyLAogCQlOSVBRVUFEKHBheWxvYWQtPmRzdF9pcCkpOwogfQpAQCAtNTM3LDEzICs1NDAsMTMgQEAKIAogCXBheWxvYWQgPSAodm9pZCAqKShhcnArMSk7CiAKLQkvKiBpZiB0aGVyZSBpcyBubyBjbHVzdGVyaXAgY29uZmlndXJhdGlvbiBmb3IgdGhlIGFycCByZXBseSdzIAorCS8qIGlmIHRoZXJlIGlzIG5vIGNsdXN0ZXJpcCBjb25maWd1cmF0aW9uIGZvciB0aGUgYXJwIHJlcGx5J3MKIAkgKiBzb3VyY2UgaXAsIHdlIGRvbid0IHdhbnQgdG8gbWFuZ2xlIGl0ICovCiAJYyA9IGNsdXN0ZXJpcF9jb25maWdfZmluZF9nZXQocGF5bG9hZC0+c3JjX2lwLCAwKTsKIAlpZiAoIWMpCiAJCXJldHVybiBORl9BQ0NFUFQ7CiAKLQkvKiBub3JtYWxseSB0aGUgbGludXgga2VybmVsIGFsd2F5cyByZXBsaWVzIHRvIGFycCBxdWVyaWVzIG9mIAorCS8qIG5vcm1hbGx5IHRoZSBsaW51eCBrZXJuZWwgYWx3YXlzIHJlcGxpZXMgdG8gYXJwIHF1ZXJpZXMgb2YKIAkgKiBhZGRyZXNzZXMgb24gZGlmZmVyZW50IGludGVyZmFjcy4gIEhvd2V2ZXIsIGluIHRoZSBDTFVTVEVSSVAgY2FzZQogCSAqIHRoaXMgd291bGRuJ3Qgd29yaywgc2luY2Ugd2UgZGlkbid0IHN1YnNjcmliZSB0aGUgbWNhc3QgZ3JvdXAgb24KIAkgKiBvdGhlciBpbnRlcmZhY2VzICovCkBAIC01NzQsOCArNTc3LDggQEAKIAkucHJpb3JpdHkgPSAtMQogfTsKIAotLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqIAotICogUFJPQyBESVIgSEFORExJTkcgCisvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioKKyAqIFBST0MgRElSIEhBTkRMSU5HCiAgKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiov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8qIHJjdV9yZWFkX2xvY2soKWVkIGJ5IG5mX2hvb2tfc2xvdyAqLworCWw0cHJvdG8gPSBfX25mX2N0X2w0cHJvdG9fZmluZChQRl9JTkVULCBpbnNpZGUtPmlwLnByb3RvY29sKTsKKwogCWlmICghbmZfY3RfZ2V0X3R1cGxlKCpwc2tiLAogCQkJICAgICAoKnBza2IpLT5uaC5pcGgtPmlobCo0ICsgc2l6ZW9mKHN0cnVjdCBpY21waGRyKSwKIAkJCSAgICAgKCpwc2tiKS0+bmguaXBoLT5paGwqNCArCi0JICAgICAgICAgICAgICAgICAgICAgc2l6ZW9mKHN0cnVjdCBpY21waGRyKSArIGluc2lkZS0+aXAuaWhsKjQsCi0JICAgICAgICAgICAgICAgICAgICAgKHVfaW50MTZfdClBRl9JTkVULAotCSAgICAgICAgICAgICAgICAgICAgIGluc2lkZS0+aXAucHJvdG9jb2wsCi0JICAgICAgICAgICAgICAgICAgICAgJmlubmVyLAotCSAgICAgICAgICAgICAgICAgICAgIGwzcHJvdG8sCi0JCQkgICAgIF9fbmZfY3RfbDRwcm90b19maW5kKCh1X2ludDE2X3QpUEZfSU5FVCwKLQkJCSAgICAgCQkJICBpbnNpZGUtPmlwLnByb3RvY29sKSkpCisJCQkgICAgIHNpemVvZihzdHJ1Y3QgaWNtcGhkcikgKyBpbnNpZGUtPmlwLmlobCo0LAorCQkJICAgICAodV9pbnQxNl90KUFGX0lORVQsCisJCQkgICAgIGluc2lkZS0+aXAucHJvdG9jb2wsCisJCQkgICAgICZpbm5lciwgbDNwcm90bywgbDRwcm90bykpCiAJCXJldHVybiAwOwogCiAJLyogQ2hhbmdlIGlubmVyIGJhY2sgdG8gbG9vayBsaWtlIGluY29taW5nIHBhY2tldC4gIFdlIGRvIHRoZQpAQCAtNTIxLDcgKzUyOCw3IEBACiAJCXJldCA9IC1FQlVTWTsKIAkJZ290byBvdXQ7CiAJfQotCW5mX25hdF9wcm90b3NbcHJvdG8tPnByb3RvbnVtXSA9IHByb3RvOwor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lnbmVkIGNoYXIgY2g7CiAKQEAgLTIwNyw4ICsyMDcsOCBAQAogfQogCiBzdGF0aWMgdW5zaWduZWQgY2hhciBhc24xX2xlbmd0aF9kZWNvZGUoc3RydWN0IGFzbjFfY3R4ICpjdHgsCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdW5zaWduZWQgaW50ICpkZWYsCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdW5zaWduZWQgaW50ICpsZW4pCisJCQkJCXVuc2lnbmVkIGludCAqZGVmLAorCQkJCQl1bnNpZ25lZCBpbnQgKmxlbikKIHsKIAl1bnNpZ25lZCBjaGFyIGNoLCBjbnQ7CiAKQEAgLTIzOSwxMCArMjM5LDEwIEBACiB9CiAKIHN0YXRpYyB1bnNpZ25lZCBjaGFyIGFzbjFfaGVhZGVyX2RlY29kZShzdHJ1Y3QgYXNuMV9jdHggKmN0eCwKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB1bnNpZ25lZCBjaGFyICoqZW9jLAotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVuc2lnbmVkIGludCAqY2xzLAotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVuc2lnbmVkIGludCAqY29uLAotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVuc2lnbmVkIGludCAqdGFnKQorCQkJCQl1bnNpZ25lZCBjaGFyICoqZW9jLAorCQkJCQl1bnNpZ25lZCBpbnQgKmNscywKKwkJCQkJdW5zaWduZWQgaW50ICpjb24sCisJCQkJCXVuc2lnbmVkIGludCAqdGFnKQogewogCXVuc2lnbmVkIGludCBkZWYsIGxlbjsKIApAQCAtMjk3LDggKzI5Nyw4IEBACiB9CiAKIHN0YXRpYyB1bnNpZ25lZCBjaGFyIGFzbjFfbG9uZ19kZWNvZGUoc3RydWN0IGFzbjFfY3R4ICpjdHgsCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVuc2lnbmVkIGNoYXIgKmVvYywKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgbG9uZyAqaW50ZWdlcikKKwkJCQkgICAgICB1bnNpZ25lZCBjaGFyICplb2MsCisJCQkJICAgICAgbG9uZyAqaW50ZWdlcikKIHsKIAl1bnNpZ25lZCBjaGFyIGNoOwogCXVuc2lnbmVkIGludCAgbGVuOwpAQCAtMzI1LDggKzMyNSw4IEBACiB9CiAKIHN0YXRpYyB1bnNpZ25lZCBjaGFyIGFzbjFfdWludF9kZWNvZGUoc3RydWN0IGFzbjFfY3R4ICpjdHgsCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVuc2lnbmVkIGNoYXIgKmVvYywKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdW5zaWduZWQgaW50ICppbnRlZ2VyKQorCQkJCSAgICAgIHVuc2lnbmVkIGNoYXIgKmVvYywKKwkJCQkgICAgICB1bnNpZ25lZCBpbnQgKmludGVnZXIpCiB7CiAJdW5zaWduZWQgY2hhciBjaDsKIAl1bnNpZ25lZCBpbnQgIGxlbjsKQEAgLTM1NCw4ICszNTQsOCBAQAogfQogCiBzdGF0aWMgdW5zaWduZWQgY2hhciBhc24xX3Vsb25nX2RlY29kZShzdHJ1Y3QgYXNuMV9jdHggKmN0eCwKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVuc2lnbmVkIGNoYXIgKmVvYywKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVuc2lnbmVkIGxvbmcgKmludGVnZXIpCisJCQkJICAgICAgIHVuc2lnbmVkIGNoYXIgKmVvYywKKwkJCQkgICAgICAgdW5zaWduZWQgbG9uZyAqaW50ZWdlcikKIHsKIAl1bnNpZ25lZCBjaGFyIGNoOwogCXVuc2lnbmVkIGludCAgbGVuOwpAQCAtMzgzLDkgKzM4Myw5IEBACiB9CiAKIHN0YXRpYyB1bnNpZ25lZCBjaGFyIGFzbjFfb2N0ZXRzX2RlY29kZShzdHJ1Y3QgYXNuMV9jdHggKmN0eCwKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB1bnNpZ25lZCBjaGFyICplb2MsCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdW5zaWduZWQgY2hhciAqKm9jdGV0cywKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB1bnNpZ25lZCBpbnQgKmxlbikKKwkJCQkJdW5zaWduZWQgY2hhciAqZW9jLAorCQkJCQl1bnNpZ25lZCBjaGFyICoqb2N0ZXRzLAorCQkJCQl1bnNpZ25lZCBpbnQgKmxlbikKIHsKIAl1bnNpZ25lZCBjaGFyICpwdHI7CiAKQEAgLTQxMSw3ICs0MTEsNyBAQAogfQogCiBzdGF0aWMgdW5zaWduZWQgY2hhciBhc24xX3N1YmlkX2RlY29kZShzdHJ1Y3QgYXNuMV9jdHggKmN0eCwKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVuc2lnbmVkIGxvbmcgKnN1YmlkKQorCQkJCSAgICAgICB1bnNpZ25lZCBsb25nICpzdWJpZCkKIHsKIAl1bnNpZ25lZCBjaGFyIGNoOwogCkBAIC00MjgsOSArNDI4LDkgQEAKIH0KIAogc3RhdGljIHVuc2lnbmVkIGNoYXIgYXNuMV9vaWRfZGVjb2RlKHN0cnVjdCBhc24xX2N0eCAqY3R4LAotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVuc2lnbmVkIGNoYXIgKmVvYywKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB1bnNpZ25lZCBsb25nICoqb2lkLAotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVuc2lnbmVkIGludCAqbGVuKQorCQkJCSAgICAgdW5zaWduZWQgY2hhciAqZW9jLAorCQkJCSAgICAgdW5zaWduZWQgbG9uZyAqKm9pZCwKKwkJCQkgICAgIHVuc2lnbmVkIGludCAqbGVuKQogewogCXVuc2lnbmVkIGxvbmcgc3ViaWQ7CiAJdW5zaWduZWQgaW50ICBzaXplOwpAQCAtNjExLDkgKzYxMSw5IEBACiAjZGVmaW5lIFNFUlJfRU9NICAgIDIKIAogc3RhdGljIGlubGluZSB2b2lkIG1hbmdsZV9hZGRyZXNzKHVuc2lnbmVkIGNoYXIgKmJlZ2luLAotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVuc2lnbmVkIGNoYXIgKmFkZHIsCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc3Qgc3RydWN0IG9jdDFfbWFwICptYXAsCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgX19zdW0xNiAqY2hlY2spOworCQkJCSAgdW5zaWduZWQgY2hhciAqYWRkciwKKwkJCQkgIGNvbnN0IHN0cnVjdCBvY3QxX21hcCAqbWFwLAorCQkJCSAgX19zdW0xNiAqY2hlY2spOwogc3RydWN0IHNubXBfY252CiB7CiAJdW5zaWduZWQgaW50IGNsYXNzOwpAQCAtNjQ0LDggKzY0NCw4IEBACiB9OwogCiBzdGF0aWMgdW5zaWduZWQgY2hhciBzbm1wX3RhZ19jbHMyc3ludGF4KHVuc2lnbmVkIGludCB0YWcsCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVuc2lnbmVkIGludCBjbHMsCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVuc2lnbmVkIHNob3J0ICpzeW50YXgpCisJCQkJCSB1bnNpZ25lZCBpbnQgY2xzLAorCQkJCQkgdW5zaWduZWQgc2hvcnQgKnN5bnRheCkKIHsKIAlzdHJ1Y3Qgc25tcF9jbnYgKmNudjsKIApAQCAtNjYyLDcgKzY2Miw3IEBACiB9CiAKIHN0YXRpYyB1bnNpZ25lZCBjaGFyI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Vlc3QgKnJlcXVlc3QpCiB7CiAJdW5zaWduZWQgaW50IGNscywgY29uLCB0YWc7CiAJdW5zaWduZWQgY2hhciAqZW5kOwpAQCAtODc0LDkgKzg3NCw5IEBACiAgKiBjb2RlIGV4YW1wbGUgaW4gdGhlIGRyYWZ0LgogICovCiBzdGF0aWMgdm9pZCBmYXN0X2NzdW0oX19zdW0xNiAqY3N1bSwKLSAgICAgICAgICAgICAgICAgICAgICBjb25zdCB1bnNpZ25lZCBjaGFyICpvcHRyLAotICAgICAgICAgICAgICAgICAgICAgIGNvbnN0IHVuc2lnbmVkIGNoYXIgKm5wdHIsCi0gICAgICAgICAgICAgICAgICAgICAgaW50IG9mZnNldCkKKwkJICAgICAgY29uc3QgdW5zaWduZWQgY2hhciAqb3B0ciwKKwkJICAgICAgY29uc3QgdW5zaWduZWQgY2hhciAqbnB0ciwKKwkJICAgICAgaW50IG9mZnNldCkKIHsKIAl1bnNpZ25lZCBjaGFyIHNbNF07CiAKQEAgLTg5OSw5ICs4OTksOSBAQAogICogICAgICAtIGFkZHIgcG9pbnRzIHRvIHRoZSBzdGFydCBvZiB0aGUgYWRkcmVzcwogICovCiBzdGF0aWMgaW5saW5lIHZvaWQgbWFuZ2xlX2FkZHJlc3ModW5zaWduZWQgY2hhciAqYmVnaW4sCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdW5zaWduZWQgY2hhciAqYWRkciwKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBjb25zdCBzdHJ1Y3Qgb2N0MV9tYXAgKm1hcCwKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBfX3N1bTE2ICpjaGVjaykKKwkJCQkgIHVuc2lnbmVkIGNoYXIgKmFkZHIsCisJCQkJICBjb25zdCBzdHJ1Y3Qgb2N0MV9tYXAgKm1hcCwKKwkJCQkgIF9fc3VtMTYgKmNoZWNrKQogewogCWlmIChtYXAtPmZyb20gPT0gTk9DVDEoYWRkcikpIHsKIAkJdV9pbnQzMl90IG9sZDsKQEAgLTkxNCw3ICs5MTQsNyBAQAogCQkvKiBVcGRhdGUgVURQIGNoZWNrc3VtIGlmIGJlaW5nIHVzZWQgKi8KIAkJaWYgKCpjaGVjaykgewogCQkJZmFzdF9jc3VtKGNoZWNrLAotCQkJICAgICAgICAgICZtYXAtPmZyb20sICZtYXAtPnRvLCBhZGRyIC0gYmVnaW4pOworCQkJCSAgJm1hcC0+ZnJvbSwgJm1hcC0+dG8sIGFkZHIgLSBiZWdpbik7CiAKIAkJfQogCkBAIC05MjUsOSArOTI1LDkgQEAKIH0KIAogc3RhdGljIHVuc2lnbmVkIGNoYXIgc25tcF90cmFwX2RlY29kZShzdHJ1Y3QgYXNuMV9jdHggKmN0eCwKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc3RydWN0IHNubXBfdjFfdHJhcCAqdHJhcCwKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc3Qgc3RydWN0IG9jdDFfbWFwICptYXAsCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIF9fc3VtMTYgKmNoZWNrKQorCQkJCSAgICAgIHN0cnVjdCBzbm1wX3YxX3RyYXAgKnRyYXAsCisJCQkJICAgICAgY29uc3Qgc3RydWN0IG9jdDFfbWFwICptYXAsCisJCQkJICAgICAgX19zdW0xNiAqY2hlY2spCiB7CiAJdW5zaWduZWQgaW50IGNscywgY29uLCB0YWcsIGxlbjsKIAl1bnNpZ25lZCBjaGFyICplbmQ7CkBAIC0xMDE5LDkgKzEwMTksOSBAQAogICogKEFuZCB0aGlzIGlzIHRoZSBmdWNraW5nICdiYXNpYycgbWV0aG9kKS4KICAqLwogc3RhdGljIGludCBzbm1wX3BhcnNlX21hbmdsZSh1bnNpZ25lZCBjaGFyICptc2csCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVfaW50MTZfdCBsZW4sCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgIGN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ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAkvKiBiZWxvdyBvcmlnaW4qLwotICAgICAgICAgICAgICAgIGJpY190YXJnZXQgPSBjYS0+YmljX29yaWdpbl9wb2ludCAtIGRlbHRhOwotICAgICAgICBlbHNlICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCS8qIGFib3ZlIG9yaWdpbiovCi0gICAgICAgICAgICAgICAgYmljX3RhcmdldCA9IGNhLT5iaWNfb3JpZ2luX3BvaW50ICsgZGVsdGE7CisJaWYgKHQgPCBjYS0+YmljX0spICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAJLyogYmVsb3cgb3JpZ2luKi8KKwkJYmljX3RhcmdldCA9IGNhLT5iaWNfb3JpZ2luX3BvaW50IC0gZGVsdGE7CisJZWxzZSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAkvKiBhYm92ZSBvcmlnaW4qLworCQliaWNfdGFyZ2V0ID0gY2EtPmJpY19vcmlnaW5fcG9pbnQgKyBkZWx0YTsKIAotICAgICAgICAvKiBjdWJpYyBmdW5jdGlvbiAtIGNhbGMgYmljdGNwX2NudCovCi0gICAgICAgIGlmIChiaWNfdGFyZ2V0ID4gY3duZCkgeworCS8qIGN1YmljIGZ1bmN0aW9uIC0gY2FsYyBiaWN0Y3BfY250Ki8KKwlpZiAoYmljX3RhcmdldCA+IGN3bmQpIHsKIAkJY2EtPmNudCA9IGN3bmQgLyAoYmljX3RhcmdldCAtIGN3bmQpOwotICAgICAgICB9IGVsc2UgewotICAgICAgICAgICAgICAgIGNhLT5jbnQgPSAxMDAgKiBjd25kOyAgICAgICAgICAgICAgLyogdmVyeSBzbWFsbCBpbmNyZW1lbnQqLwotICAgICAgICB9CisJfSBlbHNlIHsKKwkJY2EtPmNudCA9IDEwMCAqIGN3bmQ7ICAgICAgICAgICAgICAvKiB2ZXJ5IHNtYWxsIGluY3JlbWVudCovCisJfQogCiAJa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VyOgogCW5ldGxpbmtfdW5yZWdpc3Rlcl9ub3RpZmllcigmaXBxX25sX25vdGlmaWVyKTsKIAlyZXR1cm4gc3RhdHVzOwpkaWZmIC0tZ2l0IGEvbmV0L2lwdjYvbmV0ZmlsdGVyL2lwNl90YWJsZXMuYyBiL25ldC9pcHY2L25ldGZpbHRlci9pcDZfdGFibGVzLmMKaW5kZXggOTk1MDJjNS4uN2M1MTJlMSAxMDA2NDQKLS0tIGEvbmV0L2lwdjYvbmV0ZmlsdGVyL2lwNl90YWJsZXMuYworKysgYi9uZXQvaXB2Ni9uZXRmaWx0ZXIvaXA2X3RhYmxlcy5jCkBAIC05MiwxNiArOTIsMTYgQEAKICNlbmRpZgogCiAvKiBDaGVjayBmb3IgYW4gZXh0ZW5zaW9uICovCi1pbnQgCitpbnQKIGlwNnRfZXh0X2hkcih1OCBuZXh0aGRyKQogewotICAgICAgICByZXR1cm4gKCAobmV4dGhkciA9PSBJUFBST1RPX0hPUE9QVFMpICAgfHwKLSAgICAgICAgICAgICAgICAgKG5leHRoZHIgPT0gSVBQUk9UT19ST1VUSU5HKSAgIHx8Ci0gICAgICAgICAgICAgICAgIChuZXh0aGRyID09IElQUFJPVE9fRlJBR01FTlQpICB8fAotICAgICAgICAgICAgICAgICAobmV4dGhkciA9PSBJUFBST1RPX0VTUCkgICAgICAgfHwKLSAgICAgICAgICAgICAgICAgKG5leHRoZHIgPT0gSVBQUk9UT19BSCkgICAgICAgIHx8Ci0gICAgICAgICAgICAgICAgIChuZXh0aGRyID09IElQUFJPVE9fTk9ORSkgICAgICB8fAotICAgICAgICAgICAgICAgICAobmV4dGhkciA9PSBJUFBST1RPX0RTVE9QVFMpICk7CisJcmV0dXJuICggKG5leHRoZHIgPT0gSVBQUk9UT19IT1BPUFRTKSAgIHx8CisJCSAobmV4dGhkciA9PSBJUFBST1RPX1JPVVRJTkcpICAgfHwKKwkJIChuZXh0aGRyID09IElQUFJPVE9fRlJBR01FTlQpICB8fAorCQkgKG5leHR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gKCFhaGluZm8tPmhkcmxlbiB8fAotCSAgICAgICAgKGFoaW5mby0+aGRybGVuID09IGhkcmxlbikgXgotCSAgICAgICAgISEoYWhpbmZvLT5pbnZmbGFncyAmIElQNlRfQUhfSU5WX0xFTikpKTsKKwkJKGFoaW5mby0+aGRybGVuID09IGhkcmxlbikgXgorCQkhIShhaGluZm8tPmludmZsYWdzICYgSVA2VF9BSF9JTlZfTEVOKSkpOwogCURFQlVHUCgicmVzICUwMlggJTA0WCAlMDJYXG4iLAogCSAgICAgICBhaGluZm8tPmhkcnJlcywgYWgtPnJlc2VydmVkLAogCSAgICAgICAhKGFoaW5mby0+aGRycmVzICYmIGFoLT5yZXNlcnZlZCkpOwpAQCAtOTEsMTIgKzkyLDEyIEBACiAJcmV0dXJuIChhaCAhPSBOVUxMKQogCSAgICAgICAmJgogCSAgICAgICAoc3BpX21hdGNoKGFoaW5mby0+c3Bpc1swXSwgYWhpbmZvLT5zcGlzWzFdLAotCSAgICAgICAgICAgICAgICAgIG50b2hsKGFoLT5zcGkpLAotCSAgICAgICAgICAgICAgICAgICEhKGFoaW5mby0+aW52ZmxhZ3MgJiBJUDZUX0FIX0lOVl9TUEkpKSkKKwkJCSAgbnRvaGwoYWgtPnNwaSksCisJCQkgICEhKGFoaW5mby0+aW52ZmxhZ3MgJiBJUDZUX0FIX0lOVl9TUEkpKSkKIAkgICAgICAgJiYKIAkgICAgICAgKCFhaGluZm8tPmhkcmxlbiB8fAotCSAgICAgICAgKGFoaW5mby0+aGRybGVuID09IGhkcmxlbikgXgotCSAgICAgICAgISEoYWhpbmZvLT5pbnZmbGFncyAmIElQNlRfQUhfSU5WX0xFTikpCisJCShhaGluZm8tPmhkcmxlbiA9PSBoZHJsZW4pIF4KKwkJISEoYWhpbmZvLT5pbnZmbGFncyAmIElQNlRfQUhfSU5WX0xFTikpCiAJICAgICAgICYmCiAJICAgICAgICEoYWhpbmZvLT5oZHJyZXMgJiYgYWgtPnJlc2VydmVkKTsKIH0KQEAg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B0X2hkcikpIHsKKwkJaWYgKGxlbiA8IChpbnQpc2l6ZW9mKHN0cnVjdCBpcHY2X29wdF9oZHIpKSB7CiAJCQlERUJVR1AoInRvbyBzaG9ydFxuIik7CiAJCQlyZXR1cm4gLTE7CiAJCX0KLSAgICAgICAgICAgICAgICBpZiAobmV4dGhkciA9PSBORVhUSERSX05PTkUpIHsKKwkJaWYgKG5leHRoZHIgPT0gTkVYVEhEUl9OT05FKSB7CiAJCQlERUJVR1AoIm5leHQgaGVhZGVyIGlzIG5vbmVcbiIpOwogCQkJcmV0dXJuIC0xOwogCQl9Ci0gICAgICAgICAgICAgICAgaWYgKHNrYl9jb3B5X2JpdHMoc2tiLCBzdGFydCwgJmhkciwgc2l6ZW9mKGhkcikpKQotICAgICAgICAgICAgICAgICAgICAgICAgQlVHKCk7Ci0gICAgICAgICAgICAgICAgaWYgKG5leHRoZHIgPT0gTkVYVEhEUl9BVVRIKQotICAgICAgICAgICAgICAgICAgICAgICAgaGRybGVuID0gKGhkci5oZHJsZW4rMik8PDI7Ci0gICAgICAgICAgICAgICAgZWxzZQotICAgICAgICAgICAgICAgICAgICAgICAgaGRybGVuID0gaXB2Nl9vcHRsZW4oJmhkcik7CisJCWlmIChza2JfY29weV9iaXRzKHNrYiwgc3RhcnQsICZoZHIsIHNpemVvZihoZHIpKSkKKwkJCUJVRygpOworCQlpZiAobmV4dGhkciA9PSBORVhUSERSX0FVVEgpCisJCQloZHJsZW4gPSAoaGRyLmhkcmxlbisyKTw8MjsKKwkJZWxzZQorCQkJaGRybGVuID0gaXB2Nl9vcHRsZW4oJmhkcik7CiAKIAkJcHJldmhkciA9IG5leHRoZHI7CiAJCXByZXZfbmhvZmYgPSBzdGFydDsKIAotICAgICAgICAgICAgICAgIG5leHRoZHIgPSBoZHIubmV4dGhkcjsKLSAgICAgICAgICAgICAgICBsZW4gLT0gaGRybGVuOwotICAgICAgICAgICAgICAgIHN0YXJ0ICs9IGhkcmxlbjsKLSAgICAgICAgfQorCQlu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IC0xMzU5LDggKzEzNTksOCBAQAogCQkJCWludCAqZW9mLCB2b2lkICp1bnVzZWQpCiB7CiAJc3RydWN0IGlyY29tbV90dHlfY2IgKnNlbGY7Ci0gICAgICAgIGludCBjb3VudCA9IDAsIGw7Ci0gICAgICAgIG9mZl90IGJlZ2luID0gMDsKKwlpbnQgY291bnQgPSAwLCBsOworCW9mZl90IGJlZ2luID0gMDsKIAl1bnNpZ25lZCBsb25nIGZsYWdzOwogCiAJc3Bpbl9sb2NrX2lycXNhdmUoJmlyY29tbV90dHktPmhiX3NwaW5sb2NrLCBmbGFncyk7CkBAIC0xMzcwLDI1ICsxMzcwLDI1IEBACiAJCWlmIChzZWxmLT5tYWdpYyAhPSBJUkNPTU1fVFRZX01BR0lDKQogCQkJYnJlYWs7CiAKLSAgICAgICAgICAgICAgICBsID0gaXJjb21tX3R0eV9saW5lX2luZm8oc2VsZiwgYnVmICsgY291bnQpOwotICAgICAgICAgICAgICAgIGNvdW50ICs9IGw7Ci0gICAgICAgICAgICAgICAgaWYgKGNvdW50K2JlZ2luID4gb2Zmc2V0K2xlbikKLSAgICAgICAgICAgICAgICAgICAgICAgIGdvdG8gZG9uZTsKLSAgICAgICAgICAgICAgICBpZiAoY291bnQrYmVnaW4gPCBvZmZzZXQpIHsKLSAgICAgICAgICAgICAgICAgICAgICAgIGJlZ2luICs9IGNvdW50OwotICAgICAgICAgICAgICAgICAgICAgICAgY291bnQgPSAwOwotICAgICAgICAgICAgICAgIH0KLQkJCQkKKwkJbCA9IGlyY29tbV90dHlfbGluZV9pbmZvKHNlbGYsIGJ1ZiArIGNvdW50KTsKKwkJY291bnQgKz0gbDsKKwkJaWYgKGNvdW50K2JlZ2luID4gb2Zmc2V0K2xlbikKKwkJCWdvdG8gZG9uZTsKKwkJaWYgKGNvdW50K2JlZ2luIDwgb2Zmc2V0KSB7CisJCQliZWdpbiArPSBjb3VudDsKKwkJCWNvdW50ID0gMDsKKwkJfQorCiAJCXNlbGYgPSAoc3RydWN0IGlyY29tbV90dHlfY2IgKikgaGFzaGJpbl9nZXRfbmV4dChpcmNvbW1fdHR5KTsKLSAgICAgICAgfQotICAgICAgICAqZW9mID0gMTsKKwl9CisJKmVvZiA9IDE7CiBkb25lOgogCXNwaW5fdW5sb2NrX2lycXJlc3RvcmUoJmlyY29tbV90dHktPmhiX3NwaW5sb2NrLCBmbGFncyk7CiAKLSAgICAgICAgaWYgKG9mZnNldCA+PSBjb3VudCtiZWdpbikKLSAgICAgICAgICAgICAgICByZXR1cm4gMDsKLSAgICAgICAgKnN0YXJ0ID0gYnVmICsgKG9mZnNldC1iZWdpbik7Ci0gICAgICAgIHJldHVybiAoKGxlbiA8IGJlZ2luK2NvdW50LW9mZnNldCkgPyBsZW4gOiBiZWdpbitjb3VudC1vZmZzZXQpOworCWlmIChvZmZzZXQgPj0gY291bnQrYmVnaW4pCisJCXJldHVybiAwOworCSpzdGFydCA9IGJ1ZiArIChvZmZzZXQtYmVnaW4pOworCXJldHVybiAoKGxlbiA8IGJlZ2luK2NvdW50LW9mZnNldCkgPyBsZW4gOiBiZWdpbitjb3VudC1vZmZzZXQpOwogfQogI2VuZGlmIC8qIENPTkZJR19QUk9DX0ZTICovCiAKZGlmZiAtLWdpdCBhL25ldC9pcmRhL2lyY29tbS9pcmNvbW1fdHR5X2F0dGFjaC5jIGIvbmV0L2lyZGEvaXJjb21tL2lyY29tbV90dHlfYXR0YWNoLmMKaW5kZXggOTlmNWVkZC4uODI0MzA5ZCAxMDA2NDQKLS0tIGEvbmV0L2lyZGEvaXJjb21tL2lyY29tbV90dHlfYXR0YWNoLmMKKysrIGIvbmV0L2lyZGEvaXJjb21tL2lyY29tbV90dHlfYXR0YWNoLmMKQEAgLTEsMzUgKzEsMzQgQEAKIC8qKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioKLSAqICAgICAgICAgICAgICAgIAorICoKICAqIEZpbGVuYW1lOiAgICAgIGlyY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ocGFyZW50KQorCQlzay0+c2tfdHlwZSA9IHBhcmVudC0+c2tfdHlwZTsKK30KKworc3RhdGljIHN0cnVjdCBzb2NrICppdWN2X3NvY2tfYWxsb2Moc3RydWN0IHNvY2tldCAqc29jaywgaW50IHByb3RvLCBnZnBfdCBwcmlvKQoreworCXN0cnVjdCBzb2NrICpzazsKKworCXNrID0gc2tfYWxsb2MoUEZfSVVDViwgcHJpbywgJml1Y3ZfcHJvdG8sIDEpOworCWlmICghc2spCisJCXJldHVybiBOVUxMOworCisJc29ja19pbml0X2RhdGEoc29jaywgc2spOworCUlOSVRfTElTVF9IRUFEKCZpdWN2X3NrKHNrKS0+YWNjZXB0X3EpOworCXNrYl9xdWV1ZV9oZWFkX2luaXQoJml1Y3Zfc2soc2spLT5zZW5kX3NrYl9xKTsKKwlpdWN2X3NrKHNrKS0+c2VuZF90YWcgPSAwOworCisJc2stPnNrX2Rlc3RydWN0ID0gaXVjdl9zb2NrX2Rlc3RydWN0OworCXNrLT5za19zbmR0aW1lbyA9IElVQ1ZfQ09OTl9USU1FT1VUOworCXNrLT5za19hbGxvY2F0aW9uID0gR0ZQX0RNQTsKKworCXNvY2tfcmVzZXRfZmxhZyhzaywgU09DS19aQVBQRUQpOworCisJc2stPnNrX3Byb3RvY29sID0gcHJvdG87CisJc2stPnNrX3N0YXRlCT0gSVVDVl9PUEVOOworCisJaXVjdl9zb2NrX2luaXRfdGltZXIoc2spOworCisJaXVjdl9zb2NrX2xpbmsoJml1Y3Zfc2tfbGlzdCwgc2spOworCXJldHVybiBzazsKK30KKworLyogQ3JlYXRlIGFuIElVQ1Ygc29ja2V0ICovCitzdGF0aWMgaW50IGl1Y3Zfc29ja19jcmVhdGUoc3RydWN0IHNvY2tldCAqc29jaywgaW50IHByb3RvY29sKQoreworCXN0cnVjdCBzb2NrICpzazsKKworCWlmIChzb2NrLT50eXBlICE9IFNPQ0tfU1RSRUFNKQorCQlyZXR1cm4gLUVTT0NLVE5PU1VQUE9SVDsKKworCX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hPSBTT0NLX1NUUkVBTSkKKwkJZ290byBkb25lOworCisJc2stPnNrX21heF9hY2tfYmFja2xvZyA9IGJhY2tsb2c7CisJc2stPnNrX2Fja19iYWNrbG9nID0gMDsKKwlzay0+c2tfc3RhdGUgPSBJVUNWX0xJU1RFTjsKKwllcnIgPSAwOworCitkb25lOgorCXJlbGVhc2Vfc29jayhzayk7CisJcmV0dXJuIGVycjsKK30KKworLyogQWNjZXB0IGEgcGVuZGluZyBjb25uZWN0aW9uICovCitzdGF0aWMgaW50IGl1Y3Zfc29ja19hY2NlcHQoc3RydWN0IHNvY2tldCAqc29jaywgc3RydWN0IHNvY2tldCAqbmV3c29jaywKKwkJCSAgICBpbnQgZmxhZ3MpCit7CisJREVDTEFSRV9XQUlUUVVFVUUod2FpdCwgY3VycmVudCk7CisJc3RydWN0IHNvY2sgKnNrID0gc29jay0+c2ssICpuc2s7CisJbG9uZyB0aW1lbzsKKwlpbnQgZXJyID0gMDsKKworCWxvY2tfc29jayhzayk7CisKKwlpZiAoc2stPnNrX3N0YXRlICE9IElVQ1ZfTElTVEVOKSB7CisJCWVyciA9IC1FQkFERkQ7CisJCWdvdG8gZG9uZTsKKwl9CisKKwl0aW1lbyA9IHNvY2tfcmN2dGltZW8oc2ssIGZsYWdzICYgT19OT05CTE9DSyk7CisKKwkvKiBXYWl0IGZvciBhbiBpbmNvbWluZyBjb25uZWN0aW9uICovCisJYWRkX3dhaXRfcXVldWVfZXhjbHVzaXZlKHNrLT5za19zbGVlcCwgJndhaXQpOworCXdoaWxlICghKG5zayA9IGl1Y3ZfYWNjZXB0X2RlcXVldWUoc2ssIG5ld3NvY2spKSl7CisJCXNldF9jdXJyZW50X3N0YXRlKFRBU0tfSU5URVJSVVBUSUJMRSk7CisJCWlmICghdGltZW8pIHsKKwkJCWVyciA9IC1FQUdBSU47CisJCQlicmVhazsKKwkJfQorCisJCXJlbGVhc2Vfc29jayhzayk7CisJCXRpbWVvID0gc2NoZWR1bGVfdGltZW91dCh0a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qKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiogCi0gKiBFWFBFQ1QgCi0gKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiovIAorLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqCisgKiBFWFBFQ1QKKyAqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKi8KIAogc3RhdGljIGlubGluZSBpbnQKIGN0bmV0bGlua19leHBfZHVtcF90dXBsZShzdHJ1Y3Qgc2tfYnVmZiAqc2tiLApAQCAtMTA3NSw3ICsxMDc1LDcgQEAKIAkJCSBlbnVtIGN0YXR0cl9leHBlY3QgdHlwZSkKIHsKIAlzdHJ1Y3QgbmZhdHRyICpuZXN0X3Bhcm1zID0gTkZBX05FU1Qoc2tiLCB0eXBlKTsKLQkKKwogCWlmIChjdG5ldGxpbmtfZHVtcF90dXBsZXMoc2tiLCB0dXBsZSkgPCAwKQogCQlnb3RvIG5mYXR0cl9mYWlsdXJlOwogCkBAIC0xMDg1LDcgKzEwODUsNyBAQAogCiBuZmF0dHJfZmFpbHVyZToKIAlyZXR1cm4gLTE7Ci19CQkJCit9CiAKIHN0YXRpYyBpbmxpbmUgaW50CiBjdG5ldGxpbmtfZXhwX2R1bXBfbWFzayhzdHJ1Y3Qgc2tfYnVmZiAqc2tiLApAQCAtMTEyMCw3ICsxMTIwLDcgQEAKIAogc3RhdGljIGlubGluZSBpbnQKIGN0bmV0bGlua19leHBfZHVtcF9leHBlY3Qoc3RydWN0IHNrX2J1ZmYgKnNrYiwKLSAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc3Qgc3RydWN0IG5mX2Nvbm50cmFja19leHBlY3QgKmV4cCkKKwkJCSAgY29uc3Qgc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NoKGNvbnN0IHN0cnVjdCBza19idWZmICpza2IsCi0gICAgICAgICAgICAgICAgIGNvbnN0IHN0cnVjdCBuZXRfZGV2aWNlICppbiwKLSAgICAgICAgICAgICAgICAgY29uc3Qgc3RydWN0IG5ldF9kZXZpY2UgKm91dCwKLSAgICAgICAgICAgICAgICAgY29uc3Qgc3RydWN0IHh0X21hdGNoICptYXRjaCwKLSAgICAgICAgICAgICAgICAgY29uc3Qgdm9pZCAqbWF0Y2hpbmZvLAotICAgICAgICAgICAgICAgICBpbnQgb2Zmc2V0LAotICAgICAgICAgICAgICAgICB1bnNpZ25lZCBpbnQgcHJvdG9mZiwKLSAgICAgICAgICAgICAgICAgaW50ICpob3Rkcm9wKQorCQkgY29uc3Qgc3RydWN0IG5ldF9kZXZpY2UgKmluLAorCQkgY29uc3Qgc3RydWN0IG5ldF9kZXZpY2UgKm91dCwKKwkJIGNvbnN0IHN0cnVjdCB4dF9tYXRjaCAqbWF0Y2gsCisJCSBjb25zdCB2b2lkICptYXRjaGluZm8sCisJCSBpbnQgb2Zmc2V0LAorCQkgdW5zaWduZWQgaW50IHByb3RvZmYsCisJCSBpbnQgKmhvdGRyb3ApCiB7CiAJY29uc3Qgc3RydWN0IHh0X3BvbGljeV9pbmZvICppbmZvID0gbWF0Y2hpbmZvOwogCWludCByZXQ7CkBAIC0xMzQsMjcgKzEzNCwyNyBAQAogfQogCiBzdGF0aWMgaW50IGNoZWNrZW50cnkoY29uc3QgY2hhciAqdGFibGVuYW1lLCBjb25zdCB2b2lkICppcF92b2lkLAotICAgICAgICAgICAgICAgICAgICAgIGNvbnN0IHN0cnVjdCB4dF9tYXRjaCAqbWF0Y2gsCi0gICAgICAgICAgICAgICAgICAgICAgdm9pZCAqbWF0Y2hpbmZvLCB1bnNpZ25lZCBpbnQgaG9va19tYXNrKQorCQkgICAgICBjb25zdCBzdHJ1Y3QgeHRfbWF0Y2ggKm1hdGNoLAorCQkgICAgICB2b2lkICptYXRjaGluZm8sIHVuc2ln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cgc2lnbmFscyAqLwogCQlyeHJwY19kaXNjYXJkX215X3NpZ25hbHMoKTsKIAogCX0gd2hpbGUgKCFkaWUpOwpkaWZmIC0tZ2l0IGEvbmV0L3J4cnBjL21haW4uYyBiL25ldC9yeHJwYy9tYWluLmMKaW5kZXggNDhjYmQwNi4uYmFlYzFmNyAxMDA2NDQKLS0tIGEvbmV0L3J4cnBjL21haW4uYworKysgYi9uZXQvcnhycGMvbWFpbi5jCkBAIC0xNDYsMTcgKzE0NiwxNyBAQAogdm9pZCBfX2N5Z19wcm9maWxlX2Z1bmNfZW50ZXIgKHZvaWQgKnRoaXNfZm4sIHZvaWQgKmNhbGxfc2l0ZSkKIHsKICAgICAgICBhc20gdm9sYXRpbGUoIiAgbW92bCAgICAlJWVzcCwlJWVkaSAgICAgXG4iCi0gICAgICAgICAgICAgICAgICAgICIgIGFuZGwgICAgJTAsJSVlZGkgICAgICAgIFxuIgotICAgICAgICAgICAgICAgICAgICAiICBhZGRsICAgICUxLCUlZWRpICAgICAgICBcbiIKLSAgICAgICAgICAgICAgICAgICAgIiAgbW92bCAgICAlJWVzcCwlJWVjeCAgICAgXG4iCi0gICAgICAgICAgICAgICAgICAgICIgIHN1YmwgICAgJSVlZGksJSVlY3ggICAgIFxuIgotICAgICAgICAgICAgICAgICAgICAiICBzaHJsICAgICQyLCUlZWN4ICAgICAgICBcbiIKLSAgICAgICAgICAgICAgICAgICAgIiAgbW92bCAgICAkMHhlZGVkZWRlZCwlJWVheCAgICAgXG4iCi0gICAgICAgICAgICAgICAgICAgICIgIHJlcCBzdG9zbCAgICAgICAgICAgICAgIFxuIgotICAgICAgICAgICAgICAgICAgICA6Ci0gICAgICAgICAgICAgICAgICAgIDogImkiKH4oVEhSRUFEX1NJWkUtMSkpLCAiaSIoc2l6ZW9mKHN0cnVjdCB0aHJlYWRfaW5mbykpCi0gICAgICAgICAgICAgICAgICAgIDogImVheCIsICJlY3giLCAiZWRpIiwgIm1lbW9yeSIsICJjYyIKLSAgICAgICAgICAgICAgICAgICAgKTsKKwkJICAgICIgIGFuZGwgICAgJTAsJSVlZGkgICAgICAgIFxuIgorCQkgICAgIiAgYWRkbCAgICAlMSwlJWVkaSAgICAgICAgXG4iCisJCSAgICAiICBtb3ZsICAgICUlZXNwLCUlZWN4ICAgICBcbiIKKwkJICAgICIgIHN1YmwgICAgJSVlZGksJSVlY3ggICAgIFxuIgorCQkgICAgIiAgc2hybCAgICAkMiwlJWVjeCAgICAgICAgXG4iCisJCSAgICAiICBtb3ZsICAgICQweGVkZWRlZGVkLCUlZWF4ICAgICBcbiIKKwkJICAgICIgIHJlcCBzdG9zbCAgICAgICAgICAgICAgIFxuIgorCQkgICAgOgorCQkgICAgOiAiaSIofihUSFJFQURfU0laRS0xKSksICJpIihzaXplb2Yoc3RydWN0IHRocmVhZF9pbmZvKSkKKwkJICAgIDogImVheCIsICJlY3giLCAiZWRpIiwgIm1lbW9yeSIsICJjYyIKKwkJICAgICk7CiB9CiAKIHZvaWQgX19jeWdfcHJvZmlsZV9mdW5jX2V4aXQodm9pZCAqdGhpc19mbiwgdm9pZCAqY2FsbF9zaXRlKQpAQCAtMTY1LDE2ICsxNjUsMTYgQEAKIHZvaWQgX19jeWdfcHJvZmlsZV9mdW5jX2V4aXQodm9pZCAqdGhpc19mbiwgdm9pZCAqY2FsbF9zaXRlKQogewogICAgICAgIGFzbSB2b2xhdGlsZSgiICBtb3ZsICAgICUlZXNwLCUlZWRpICAgICBcbiIKLSAgICAgICAgICAgICAgICAgICAgIiAgYW5kbCAgICAlMCwlJWVkaSAgICAgICAgXG4iCi0gICAgICAgICAgICAgICAgICAgICIgIGFkZGwgICAgJTEsJSVlZGkgICAgICAgIFxuIgotICAgICAgICAgICAgICAgICAgICAiICBtb3ZsICAgICUlZXNwLCUlZWN4ICAgICBcbiIKLSAgICAgICAgICAgICAgICAgICAgIiAgc3VibCAgICAlJWVkaSwlJWVjeCAgICAgXG4iCi0gICAgICAgICAgICAgICAgICAgICIgIHNocmwgICAgJDIsJSVlY3ggICAgICAgIFxuIgotICAgICAgICAgICAgICAgICAgICAiICBtb3ZsICAgICQweGRhZGFkYWRhLCUlZWF4ICAgICBcbiIKLSAgICAgICAgICAgICAgICAgICAgIiAgcmVwIHN0b3NsICAgICAgICAgICAgICAgXG4iCi0gICAgICAgICAgICAgICAgICAgIDoKLSAgICAgICAgICAgICAgICAgICAgOiAiaSIofihUSFJFQURfU0laRS0xKSksICJpIihzaXplb2Yoc3RydWN0IHRocmVhZF9pbmZvKSkKLSAgICAgICAgICAgICAgICAgICAgOiAiZWF4IiwgImVjeCIsICJlZGkiLCAibWVtb3J5IiwgImNjIgotICAgICAgICAgICAgICAgICAgICApOworCQkgICAgIiAgYW5kbCAgICAlMCwlJWVkaSAgICAgICAgXG4iCisJCSAgICAiICBhZGRsICAgICUxLCUlZWRpICAgICAgICBcbiIKKwkJICAgICIgIG1vdmwgICAgJSVlc3AsJSVlY3ggICAgIFxuIgorCQkgICAgIiAgc3VibCAgICAlJWVkaSwlJWVjeCAgICAgXG4iCisJCSAgICAiICBzaHJsICAgICQyLCUlZWN4ICAgICAgICBcbiIKKwkJICAgICIgIG1vdmwgICAgJDB4ZGFkYWRhZGEsJSVlYXggICAgIFxuIgorCQkgICAgIiAgcmVwIHN0b3NsICAgICAgICAgICAgICAgXG4iCisJCSAgICA6CisJCSAgICA6ICJpIih+KFRIUkVBRF9TSVpFLTEpKSwgImkiKHNpemVvZihzdHJ1Y3QgdGhyZWFkX2luZm8pKQorCQkgICAgOiAiZWF4IiwgImVjeCIsICJlZGkiLCAibWVtb3J5IiwgImNjIgorCQkgICAgKTsKIH0KICNlbmRpZgpkaWZmIC0tZ2l0IGEvbmV0L3J4cnBjL3Byb2MuYyBiL25ldC9yeHJwYy9wcm9jLmMKaW5kZXggMjk5NzVkOS4uODU1MWM4NyAxMDA2NDQKLS0tIGEvbmV0L3J4cnBjL3Byb2MuYworKysgYi9uZXQvcnhycGMvcHJvYy5jCkBAIC0zNyw3ICszNyw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Y3BfYnVmOworCXN0cnVjdCBwcmludF9idWYgY2I7CiAKIAlpZiAoIXBiLT5idWYpCiAJCXJldHVybiAwOwogCiAJaWYgKHBiLT5idWZbcGItPnNpemUgLSAxXSA9PSAwKSB7Ci0gICAgICAgICAgICAgICAgY3BfYnVmID0ga21hbGxvYyhwYi0+c2l6ZSwgR0ZQX0FUT01JQyk7Ci0gICAgICAgICAgICAgICAgaWYgKGNwX2J1ZiAhPSBOVUxMKXsKLSAgICAgICAgICAgICAgICAgICAgICAgIHRpcGNfcHJpbnRidWZfaW5pdCgmY2IsIGNwX2J1ZiwgcGItPnNpemUpOwotICAgICAgICAgICAgICAgICAgICAgICAgdGlwY19wcmludGJ1Zl9tb3ZlKCZjYiwgcGIpOwotICAgICAgICAgICAgICAgICAgICAgICAgdGlwY19wcmludGJ1Zl9tb3ZlKHBiLCAmY2IpOwotICAgICAgICAgICAgICAgICAgICAgICAga2ZyZWUoY3BfYnVmKTsKLSAgICAgICAgICAgICAgICAgICAgICAgIG1lbWNweShwYi0+YnVmLCBlcnIsIHN0cmxlbihlcnIpKTsKLSAgICAgICAgICAgICAgICB9IGVsc2UgewotICAgICAgICAgICAgICAgICAgICAgICAgdGlwY19wcmludGJ1Zl9yZXNldChwYik7Ci0gICAgICAgICAgICAgICAgICAgICAgICB0aXBjX3ByaW50ZihwYiwgZXJyKTsKLSAgICAgICAgICAgICAgICB9CisJCWNwX2J1ZiA9IGttYWxsb2MocGItPnNpemUsIEdGUF9BVE9NSUMpOworCQlpZiAoY3BfYnVmICE9IE5VTEwpeworCQkJdGlwY19wcmludGJ1Zl9pbml0KCZjYiwgY3BfYnVmLCBwYi0+c2l6ZSk7CisJCQl0aXBjX3ByaW50YnVmX21vdmUoJmNiLCBwYik7CisJCQl0aXBjX3ByaW50YnVmX21vdmUocGIsICZjYik7CisJCQlrZnJlZShjcF9idWYpOworCQkJbWVtY3B5KHBiLT5idWYsIGVyciwgc3RybGVuKGVycikpOworCQl9IGVsc2UgeworCQkJ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QkJICAgIGxfcHRyLT5mc21fbXNnX2NudCkgewogCQkJCW1zZ19zaXplID0gKG10dSArIChsX3B0ci0+bWF4X3BrdF90YXJnZXQgLSBtdHUpLzIgKyAyKSAmIH4zOwotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAobF9wdHItPm1heF9wa3RfcHJvYmVzID09IDEwKSB7Ci0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgbF9wdHItPm1heF9wa3RfdGFyZ2V0ID0gKG1zZ19zaXplIC0gNCk7Ci0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgbF9wdHItPm1heF9wa3RfcHJvYmVzID0gMDsKKwkJCQlpZiAobF9wdHItPm1heF9wa3RfcHJvYmVzID09IDEwKSB7CisJCQkJCWxfcHRyLT5tYXhfcGt0X3RhcmdldCA9IChtc2dfc2l6ZSAtIDQpOworCQkJCQlsX3B0ci0+bWF4X3BrdF9wcm9iZXMgPSAwOwogCQkJCQltc2dfc2l6ZSA9IChtdHUgKyAobF9wdHItPm1heF9wa3RfdGFyZ2V0IC0gbXR1KS8yICsgMikgJiB+MzsKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfQorCQkJCX0KIAkJCQlsX3B0ci0+bWF4X3BrdF9wcm9iZXMrKzsKLSAgICAgICAgICAgICAgICAgICAgICAgIH0KKwkJCX0KIAogCQkJbF9wdHItPnN0YXRzLnNlbnRfcHJvYmVzKys7Ci0gICAgICAgICAgICAgICAgfQorCQl9CiAJCWxfcHRyLT5zdGF0cy5zZW50X3N0YXRlcysrOwogCX0gZWxzZSB7CQkvKiBSRVNFVF9NU0cgb3IgQUNUSVZBVEVfTVNHICovCiAJCW1zZ19zZXRfYWNrKG1zZywgbW9kKGxfcHRyLT5yZXNldF9jaGVja3BvaW50IC0gMSkpOwpAQCAtMjE0NCw3ICsyMTQ0LDcgQEAKIAkJcmV0dXJuOwogCiAJbWVtY3B5KGJ1Zi0+ZGF0YSwgK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gICAgICBkYmcoIkxpbmsgPCVzPiB1cGRhdGVkIE1UVSAldSAtPiAldVxuIiwKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICBsX3B0ci0+bmFtZSwgbF9wdHItPm1heF9wa3QsIG1heF9wa3RfYWNrKTsKLSAgICAgICAgICAgICAgICAgICAgICAgIGxfcHRyLT5tYXhfcGt0ID0gbWF4X3BrdF9hY2s7Ci0gICAgICAgICAgICAgICAgICAgICAgICBsX3B0ci0+bWF4X3BrdF9wcm9iZXMgPSAwOwotICAgICAgICAgICAgICAgIH0KKwkJaWYgKG1heF9wa3RfYWNrID4gbF9wdHItPm1heF9wa3QpIHsKKwkJCWRiZygiTGluayA8JXM+IHVwZGF0ZWQgTVRVICV1IC0+ICV1XG4iLAorCQkJICAgIGxfcHRyLT5uYW1lLCBsX3B0ci0+bWF4X3BrdCwgbWF4X3BrdF9hY2spOworCQkJbF9wdHItPm1heF9wa3QgPSBtYXhfcGt0X2FjazsKKwkJCWxfcHRyLT5tYXhfcGt0X3Byb2JlcyA9IDA7CisJCX0KIAogCQltYXhfcGt0X2FjayA9IDA7Ci0gICAgICAgICAgICAgICAgaWYgKG1zZ19wcm9iZShtc2cpKSB7CisJCWlmIChtc2dfcHJvYmUobXNnKSkgewogCQkJbF9wdHItPnN0YXRzLnJlY3ZfcHJvYmVzKys7Ci0gICAgICAgICAgICAgICAgICAgICAgICBpZiAobXNnX3NpemUobXNnKSA+IHNpemVvZihsX3B0ci0+cHJvdG9fbXNnKSkgewotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBtYXhfcGt0X2FjayA9IG1zZ19zaXplKG1zZyk7Ci0gICAgICAgICAgICAgICAgICAgICAgICB9Ci0gICAgICAgICAgICAgICAgfQorCQkJaWYgKG1zZ19zaXplKG1zZykgPiBzaXplb2YobF9wdHItPnByb3RvX21zZykpIHsKKwkJCQltYXhfcGt0X2FjayA9IG1zZ19zaXplKG1zZyk7CisJCQl9CisJCX0KIAogCQkvKiBQcm90b2N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CBsaW5rIHRvICVzXG4iLAorCQkJZXJyKCJBdHRlbXB0IHRvIGNyZWF0ZSB0aGlyZCBsaW5rIHRvICVzXG4iLAogCQkJICAgIGFkZHJfc3RyaW5nX2ZpbGwoYWRkcl9zdHJpbmcsIG5fcHRyLT5hZGRyKSk7Ci0gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gTlVMTDsKLSAgICAgICAgICAgICAgICB9CisJCQlyZXR1cm4gTlVMTDsKKwkJfQogCi0gICAgICAgICAgICAgICAgaWYgKCFuX3B0ci0+bGlua3NbYmVhcmVyX2lkXSkgewotICAgICAgICAgICAgICAgICAgICAgICAgbl9wdHItPmxpbmtzW2JlYXJlcl9pZF0gPSBsX3B0cjsKLSAgICAgICAgICAgICAgICAgICAgICAgIHRpcGNfbmV0LnpvbmVzW3RpcGNfem9uZShsX3B0ci0+YWRkcildLT5saW5rcysrOwotICAgICAgICAgICAgICAgICAgICAgICAgbl9wdHItPmxpbmtfY250Kys7Ci0gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gbl9wdHI7Ci0gICAgICAgICAgICAgICAgfQotICAgICAgICAgICAgICAgIGVycigiQXR0ZW1wdCB0byBlc3RhYmxpc2ggc2Vjb25kIGxpbmsgb24gPCVzPiB0byAlcyBcbiIsCi0gICAgICAgICAgICAgICAgICAgIGxfcHRyLT5iX3B0ci0+cHVibC5uYW1lLCAKKwkJaWYgKCFuX3B0ci0+bGlua3NbYmVhcmVyX2lkXSkgeworCQkJbl9wdHItPmxpbmtzW2JlYXJlcl9pZF0gPSBsX3B0cjsKKwkJCXRpcGNfbmV0LnpvbmVzW3RpcGNfem9uZShsX3B0ci0+YWRkcildLT5saW5rcysrOworCQkJbl9wdHItPmxpbmtfY250Kys7CisJCQlyZXR1cm4gbl9wdHI7CisJCX0KKwkJZXJyKCJBdHRlbXB0IHRvIGVzdGFibGlzaCBzZWNvbmQgbGluayBvbiA8JXM+IHRvICVzIFxuIiwKKwkJICAgIGxfcHRyLT5iX3B0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wogCiAJZm9yIChuX3B0ciA9IHRpcGNfbm9kZXM7IG5fcHRyOyBuX3B0ciA9IG5fcHRyLT5uZXh0KSB7Ci0gICAgICAgICAgICAgICAgdTMyIGk7CisJCXUzMiBpOwogCiAJCWlmICghaW5fc2NvcGUoZG9tYWluLCBuX3B0ci0+YWRkcikpCiAJCQljb250aW51ZTsKLSAgICAgICAgICAgICAgICBmb3IgKGkgPSAwOyBpIDwgTUFYX0JFQVJFUlM7IGkrKykgewotICAgICAgICAgICAgICAgICAgICAgICAgaWYgKCFuX3B0ci0+bGlua3NbaV0pIAotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBjb250aW51ZTsKLSAgICAgICAgICAgICAgICAgICAgICAgIGxpbmtfaW5mby5kZXN0ID0gaHRvbmwobl9wdHItPmFkZHIpOwotICAgICAgICAgICAgICAgICAgICAgICAgbGlua19pbmZvLnVwID0gaHRvbmwodGlwY19saW5rX2lzX3VwKG5fcHRyLT5saW5rc1tpXSkpOwotICAgICAgICAgICAgICAgICAgICAgICAgc3RyY3B5KGxpbmtfaW5mby5zdHIsIG5fcHRyLT5saW5rc1tpXS0+bmFtZSk7Ci0JCQl0aXBjX2NmZ19hcHBlbmRfdGx2KGJ1ZiwgVElQQ19UTFZfTElOS19JTkZPLCAKKwkJZm9yIChpID0gMDsgaSA8IE1BWF9CRUFSRVJTOyBpKyspIHsKKwkJCWlmICghbl9wdHItPmxpbmtzW2ldKQorCQkJCWNvbnRpbnVlOworCQkJbGlua19pbmZvLmRlc3QgPSBodG9ubChuX3B0ci0+YWRkcik7CisJCQlsaW5rX2luZm8udXAgPSBodG9ubCh0aXBjX2xpbmtfaXNfdXAobl9wdHItPmxpbmtzW2ldKSk7CisJCQlzdHJjcHkobGlua19pbmZvLnN0ciwgbl9wdHItPmxpbmtzW2ldLT5uYW1lKTsKKwkJCXRpcGNfY2ZnX2FwcGVuZF90bHYoYnVmLCBUSVBDX1RMVl9MSU5LX0lORk8sCiAJCQkJCSAgICAmbGl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cG9ydF9wZWVybm9kZShwX3B0cik7CisJaWYgKHBfcHRyLT5wdWJsLmNvbm5lY3RlZCkgeworCQl1MzIgZHBvcnQgPSBwb3J0X3BlZXJwb3J0KHBfcHRyKTsKKwkJdTMyIGRlc3Rub2RlID0gcG9ydF9wZWVybm9kZShwX3B0cik7CiAKLSAgICAgICAgICAgICAgICB0aXBjX3ByaW50ZihidWYsICIgY29ubmVjdGVkIHRvIDwldS4ldS4ldToldT4iLAotICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRpcGNfem9uZShkZXN0bm9kZSksIHRpcGNfY2x1c3RlcihkZXN0bm9kZSksCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgdGlwY19ub2RlKGRlc3Rub2RlKSwgZHBvcnQpOwotICAgICAgICAgICAgICAgIGlmIChwX3B0ci0+cHVibC5jb25uX3R5cGUgIT0gMCkKLSAgICAgICAgICAgICAgICAgICAgICAgIHRpcGNfcHJpbnRmKGJ1ZiwgIiB2aWEgeyV1LCV1fSIsCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBwX3B0ci0+cHVibC5jb25uX3R5cGUsCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBwX3B0ci0+cHVibC5jb25uX2luc3RhbmNlKTsKLSAgICAgICAgfQotICAgICAgICBlbHNlIGlmIChwX3B0ci0+cHVibC5wdWJsaXNoZWQpIHsKLSAgICAgICAgICAgICAgICB0aXBjX3ByaW50ZihidWYsICIgYm91bmQgdG8iKTsKLSAgICAgICAgICAgICAgICBsaXN0X2Zvcl9lYWNoX2VudHJ5KHB1YmwsICZwX3B0ci0+cHVibGljYXRpb25zLCBwcG9ydF9saXN0KSB7CisJCXRpcGNfcHJpbnRmKGJ1ZiwgIiBjb25uZWN0ZWQgdG8gPCV1LiV1LiV1OiV1PiIsCisJCQkgICAgdGlwY196b25lKGRlc3Rub2RlKSwgdGlwY19jbHVzdGVyKGRlc3Rub2RlKSwKKwkJCSAgICB0aXBjX25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gICAgICAgICAgICAgICAgICAgICAgIGdvdG8gZXhpdDsKLSAgICAgICAgICAgICAgICAgICAgICAgIHJlcyA9IHRpcGNfc2VuZDJuYW1lKHRzb2NrLT5wLT5yZWYsCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAmZGVzdC0+YWRkci5uYW1lLm5hbWUsCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBkZXN0LT5hZGRyLm5hbWUuZG9tYWluLCAKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIG0tPm1zZ19pb3ZsZW4sCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBtLT5tc2dfaW92KTsKLSAgICAgICAgICAgICAgICB9Ci0gICAgICAgICAgICAgICAgZWxzZSBpZiAoZGVzdC0+YWRkcnR5cGUgPT0gVElQQ19BRERSX0lEKSB7Ci0gICAgICAgICAgICAgICAgICAgICAgICByZXMgPSB0aXBjX3NlbmQycG9ydCh0c29jay0+cC0+cmVmLAotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgJmRlc3QtPmFkZHIuaWQsCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBtLT5tc2dfaW92bGVuLAotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgbS0+bXNnX2lvdik7Ci0gICAgICAgICAgICAgICAgfQotICAgICAgICAgICAgICAgIGVsc2UgaWYgKGRlc3QtPmFkZHJ0eXBlID09IFRJUENfQUREUl9NQ0FTVCkgeworCWRvIHsKKwkJaWYgKGRlc3QtPmFkZHJ0eXBlID09IFRJUENfQUREUl9OQU1FKSB7CisJCQlpZiAoKHJlcyA9IGRlc3RfbmFtZV9jaGVjayhkZXN0LCBtKSkpCisJCQkJZ290byBleGl0OworCQkJcmVzID0gdGlwY19zZW5kMm5hbWUodHNvY2stPnAtPnJlZiwKKwkJCQkJICAgICAmZGVzdC0+YWRkci5uYW1lLm5hbWUsCisJCQkJCSAgICAgZGVzdC0+YWRkci5uYW1lLmRvbWFpbiwKKwkJCQkJICAgICBtLT5tc2dfaW92bGVuLAorCQkJCQkgICAgIG0tPm1zZ19pb3YpOworCQl9CisJCWVsc2UgaWYgKGRlc3QtPmFkZHJ0eXBlID09IFRJUENfQUREUl9JRCkgeworCQkJcmVzID0gdGlwY19zZW5kMnBvcnQodHNvY2stPnAtPnJlZiwKKwkJCQkJICAgICAmZGVzdC0+YWRkci5pZCwKKwkJCQkJICAgICBtLT5tc2dfaW92bGVuLAorCQkJCQkgICAgIG0tPm1zZ19pb3YpOworCQl9CisJCWVsc2UgaWYgKGRlc3QtPmFkZHJ0eXBlID09IFRJUENfQUREUl9NQ0FTVCkgewogCQkJaWYgKG5lZWRzX2Nvbm4pIHsKIAkJCQlyZXMgPSAtRU9QTk9UU1VQUDsKIAkJCQlnb3RvIGV4aXQ7CiAJCQl9Ci0gICAgICAgICAgICAgICAgICAgICAgICBpZiAoKHJlcyA9IGRlc3RfbmFtZV9jaGVjayhkZXN0LCBtKSkpCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGdvdG8gZXhpdDsKLSAgICAgICAgICAgICAgICAgICAgICAgIHJlcyA9IHRpcGNfbXVsdGljYXN0KHRzb2NrLT5wLT5yZWYsCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAmZGVzdC0+YWRkci5uYW1lc2VxLAotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgMCwKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIG0tPm1zZ19pb3ZsZW4sCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBtLT5tc2dfaW92KTsKLSAgICAgICAgICAgICAgICB9Ci0gICAgICAgICAgICAgICAgaWYgKGxpa2VseShyZXMgIT0gLUVMSU5LQ09ORykpIHsKLWV4aXQ6ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKLSAgICAgICAgICAgICAgICAgICAgICAgIHVwKCZ0c29jay0+c2VtKTsKLSAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiByZXM7Ci0gICAgICAgICAgICAgICAgfQorCQkJaWYgKChyZXMgPSBkZXN0X25hbWVfY2hlY2soZGVzdCwgbSkpKQorCQkJCWdvdG8gZXhpdDsKKwkJCXJlcyA9IHRpcGNfbXVsdGljYXN0KHRzb2NrLT5wLT5yZWYsCisJCQkJCSAgICAgJmRlc3QtPmFkZHIubmFtZXNlcSwKKwkJCQkJICAgICAwLAorCQkJCQkgICAgIG0tPm1zZ19pb3ZsZW4sCisJCQkJCSAgICAgbS0+bXNnX2lvdik7CisJCX0KKwkJaWYgKGxpa2VseShyZXMgIT0gLUVMSU5LQ09ORykpIHsKK2V4aXQ6CisJCQl1cCgmdHNvY2stPnNlbSk7CisJCQlyZXR1cm4gcmVzOworCQl9CiAJCWlmIChtLT5tc2dfZmxhZ3MgJiBNU0dfRE9OVFdBSVQpIHsKIAkJCXJlcyA9IC1FV09VTERCTE9DSzsKIAkJCWdvdG8gZXhpdDsKIAkJfQotICAgICAgICAgICAgICAgIGlmICh3YWl0X2V2ZW50X2ludGVycnVwdGlibGUoKnNvY2stPnNrLT5za19zbGVlcCwKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICF0c29jay0+cC0+Y29uZ2VzdGVkKSkgewotICAgICAgICAgICAgICAgICAgICByZXMgPSAtRVJFU1RBUlRTWVM7Ci0gICAgICAgICAgICAgICAgICAgIGdvdG8gZXhpdDsKLSAgICAgICAgICAgICAgICB9Ci0gICAgICAgIH0gd2hpbGUgKDEpOworCQlpZiAod2FpdF9ldmVudF9pbnRlcnJ1cHRpYmxlKCpzb2NrLT5zay0+c2tfc2xlZXAsCisJCQkJCSAgICAgIXRzb2NrLT5wLT5jb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3V0ZXIvYWZfd2FucGlwZS5jCkBAIC0xMSwxMSArMTEsMTEgQEAKICoJCTIgb2YgdGhlIExpY2Vuc2UsIG9yIChhdCB5b3VyIG9wdGlvbikgYW55IGxhdGVyIHZlcnNpb24uCiAqID09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KICogRHVlIENyZWRpdDoKLSogICAgICAgICAgICAgICBXYW5waXBlIHNvY2tldCBsYXllciBpcyBiYXNlZCBvbiBQYWNrZXQgYW5kIAotKiAgICAgICAgICAgICAgIHRoZSBYMjUgc29ja2V0IGxheWVycy4gVGhlIGFib3ZlIHNvY2tldHMgd2VyZSAKLSogICAgICAgICAgICAgICB1c2VkIGZvciB0aGUgc3BlY2lmaWMgdXNlIG9mIFNhbmdvbWEgVGVjaG5vbG9naWVzIAotKiAgICAgICAgICAgICAgIEFQSSBwcm9ncmFtcy4gCi0qICAgICAgICAgICAgICAgUGFja2V0IHNvY2tldCBBdXRob3JzOiBSb3NzIEJpcm8sIEZyZWQgTi4gdmFuIEtlbXBlbiBhbmQgCisqICAgICAgICAgICAgICAgV2FucGlwZSBzb2NrZXQgbGF5ZXIgaXMgYmFzZWQgb24gUGFja2V0IGFuZAorKiAgICAgICAgICAgICAgIHRoZSBYMjUgc29ja2V0IGxheWVycy4gVGhlIGFib3ZlIHNvY2tldHMgd2VyZQorKiAgICAgICAgICAgICAgIHVzZWQgZm9yIHRoZSBzcGVjaWZpYyB1c2Ugb2YgU2FuZ29tYSBUZWNobm9sb2dpZXMKKyogICAgICAgICAgICAgICBBUEkgcHJvZ3JhbXMuCisqICAgICAgICAgICAgICAgUGFja2V0IHNvY2tldCBBdXRob3JzOiBSb3NzIEJpcm8sIEZyZWQgTi4gdmFuIEtlbXBlbiBhbmQKICogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIEFsYW4gQ294LgogKiAgICAgICAgICAgICAgIFgyNSBzb2NrZXQgQXV0aG9yOiBKb25hdGhhbiBOYXlsb3IuCiAqID09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KQEAgLTI4LDcgKzI4LDcgQEAKICogRmViIDI5LCAyMDAwICBOZW5hZCBDb3JiaWMgICAgIG8gQWRkZWQgc3VwcG9ydCBmb3IgUFZDIHByb3RvY29scywgc3VjaCBhcwogKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBDSERMQywgRnJhbWUgUmVsYXkgYW5kIEhETEMgQVBJLgogKiBKYW4gMTcsIDIwMDAgCU5lbmFkIENvcmJpYwkgbyBJbml0aWFsIHZlcnNpb24sIGJhc2VkIG9uIEFGX1BBQ0tFVCBzb2NrZXQuCi0qCQkJICAgICAgICAgICBYMjVBUEkgc3VwcG9ydCBvbmx5LiAKKyoJCQkgICAgICAgICAgIFgyNUFQSSBzdXBwb3J0IG9ubHkuCiAqCiAqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiovCiAKQEAgLTcxLDMzICs3MSwzMyBAQAogCSNkZWZpbmUgREJHX1BSSU5USyhmb3JtYXQsIGEuLi4pIHByaW50ayhmb3JtYXQsICMjIGEpCiAjZWxzZQogCSNkZWZpbmUgREJHX1BSSU5USyhmb3JtYXQsIGEuLi4pCi0jZW5kaWYgICAgICAKKyNlbmRpZgogCiAKLS8qIFNFQ1VSRSBTT0NLRVQgSU1QTEVNRU5UQVRJT04gCi0gKiAKKy8qIFNFQ1VSRSBTT0NLRVQgSU1QTEVNRU5UQVRJT04KKyAqCiAgKiAgIFRSQU5TTUlUOgogICoKICAqICAgICAgV2hlbiB0aGUgdXNlciBzZW5kcyBhIHBhY2tldCB2aWEgc2VuZCgpIHN5c3RlbSBjYWxsCi0gKiAgICAgIHRoZSB3YW5waXBlX3NlbmRtc2coKSBmdW5jdGlvbi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IHsKIAkJCWF0b21pY19zZXQoJnNrLT5za19yZWZjbnQsIDEpOwogCQkJREJHX1BSSU5USyhLRVJOX0lORk8gIndhbnNvY2s6IEVycm9yLCB3cm9uZyByZWZlcmVuY2UgY291bnQ6ICVpICEgOmRlbGF5LlxuIiwKQEAgLTg2NSw5ICs4NjUsOSBAQAogLyo9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KICAqIHdhbnBpcGVfdW5saW5rX2RyaXZlcgogICoKLSAqIAlXaGVuIHRoZSBzb2NrZXQgaXMgcmVsZWFzZWQsIHRoaXMgZnVuY3Rpb24gaXMgCisgKiAJV2hlbiB0aGUgc29ja2V0IGlzIHJlbGVhc2VkLCB0aGlzIGZ1bmN0aW9uIGlzCiAgKiAgICAgIHVzZWQgdG8gcmVtb3ZlIGxpbmtzIHRoYXQgYmluZCB0aGUgc29jayBhbmQgdGhlCi0gKiAgICAgIGRyaXZlciB0b2dldGhlci4gIAorICogICAgICBkcml2ZXIgdG9nZXRoZXIuCiAgKj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09Ki8KIHN0YXRpYyB2b2lkIHdhbnBpcGVfdW5saW5rX2RyaXZlciAoc3RydWN0IHNvY2sgKnNrKQogewpAQCAtODgyLDcgKzg4Miw3IEBACiAJaWYgKCFkZXYpewogCQlwcmludGsoS0VSTl9JTkZPICJ3YW5zb2NrOiBObyBkZXYgb24gcmVsZWFzZVxuIik7CiAJCXJldHVybjsKLQl9CQkJCisJfQogCWRldl9wdXQoZGV2KTsKIAogCWlmICgoY2hhbiA9IGRldi0+cHJpdikgPT0gTlVMTCl7CkBAIC04OTcsNyArODk3LDcgQEAKIAljaGFuLT50eF90aW1lcj1OVUxMOwogCWNsZWFyX2JpdCgwLCZjaGFuLT5jb21tb25fY3JpdGljYWwpOwogCXJlbGVhc2VfZGV2aWNlKGRldik7Ci0JCisKIAlyZXR1cm47CiB9CiAKQEAgLTkzMSw3ICs5MzEsNyBAQAogLyo9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KICAqIHJlbGVhc2VfZGV2aWNlCiAgKgotICogICAJRHVyaW5nIHNvY2sgcmVsZWFzZSwgY2xlYXIgYSBjcml0aWNhbCBiaXQsIHdoaWNoIAorICogICAJRHVyaW5nIHNvY2sgcmVsZWFzZSwgY2xlYXIgYSBjcml0aWNhbCBiaXQsIHdoaWNoCiAgKiAgICAgIG1hcmtzIHRoZSBkZXZpY2UgYSBiZWluZyB0YWtlbi4KICAqPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0qLwogCkBAIC05NDUsOCArOTQ1LDggQEAKIC8qPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09CiAgKiB3YW5waXBlX3JlbGVhc2UKICAqCi0gKglDbG9zZSBhIFBBQ0tFVCBzb2NrZXQuIFRoaXMgaXMgZmFpcmx5IHNpbXBsZS4gV2UgCi0gKiAgICAgIGltbWVkaWF0ZWx5IGdvIHRvICdjbG9zZWQnIHN0YXRlIGFuZCByZW1vdmUgb3VyIAorICoJQ2xvc2UgYSBQQUNLRVQgc29ja2V0LiBUaGlzIGlzIGZhaXJseSBzaW1wbGUuIFdlCisgKiAgICAgIGltbWVkaWF0ZWx5IGdvIHRvICdjbG9zZWQnIHN0YXRlIGFuZCByZW1vdmUgb3VyCiAgKiAgICAgIHByb3RvY29sIGVudHJ5IGluIHRoZSBkZXZpY2UgbGlzdC4KICAqPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0qLwogCkBAIC05NTQsNyArOTU0LDcgQEAKIHsKIAl3YW5waXBlX29wdCAqd3A7CiAJc3RydWN0IHNvY2sgKnNrID0gc29jay0+c2s7Ci0JCisKIAlpZiA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KIC8qPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09CiAgKiBjaGVja193cml0ZV9xdWV1ZQogICoKLSAqICAJRHVyaW5nIHNvY2sgc2h1dGRvd24sIGlmIHRoZSBzb2NrIHN0YXRlIGlzIAotICogICAgICBXQU5TT0NLX0NPTk5FQ1RFRCBhbmQgdGhlcmUgaXMgdHJhbnNtaXQgZGF0YSAKLSAqICAgICAgcGVuZGluZy4gV2FpdCB1bnRpbCBkYXRhIGlzIHJlbGVhc2VkIAorICogIAlEdXJpbmcgc29jayBzaHV0ZG93biwgaWYgdGhlIHNvY2sgc3RhdGUgaXMKKyAqICAgICAgV0FOU09DS19DT05ORUNURUQgYW5kIHRoZXJlIGlzIHRyYW5zbWl0IGRhdGEKKyAqICAgICAgcGVuZGluZy4gV2FpdCB1bnRpbCBkYXRhIGlzIHJlbGVhc2VkCiAgKiAgICAgIGJlZm9yZSBwcm9jZWVkaW5nLgogICo9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PSovCiAKQEAgLTEwNjIsNyArMTA2Miw3IEBACiAvKj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PQogICogcmVsZWFzZV9kcml2ZXIKICAqCi0gKglUaGlzIGZ1bmN0aW9uIGlzIGNhbGxlZCBkdXJpbmcgc29jayBzaHV0ZG93biwgdG8gCisgKglUaGlzIGZ1bmN0aW9uIGlzIGNhbGxlZCBkdXJpbmcgc29jayBzaHV0ZG93biwgdG8KICAqICAgICAgcmVsZWFzZSBhbnkgcmVzb3VyY2VzIGFuZCBsaW5rcyB0aGF0IGJpbmQgdGhlIHNvY2sKICAqICAgICAgdG8gdGhlIGRyaXZlci4gIEl0IGFsc28gY2hhbmdlcyB0aGUgc3RhdGUgb2YgdGhlCiAgKiAgICAgIHNvY2sgdG8gV0FOU09DS19ESVNDT05ORUNURUQKQEAgLTExMDUsNyArMTEwNSw3IEBACiAgKiAgc3RhcnRfY2xlYW51cF90aW1lcgogICoKICAqICAJSWYgbmV3IGluY29taW5nIGNhbGwncyBhcmUgcGVuZGluZyBidXQgdGhlIHNvY2tldAotICogICAgICBpcyBiZWluZyByZWxlYXNlZCwgc3RhcnQgdGhlIHRpbWVyIHdoaWNoIHdpbGwgCisgKiAgICAgIGlzIGJlaW5nIHJlbGVhc2VkLCBzdGFydCB0aGUgdGltZXIgd2hpY2ggd2lsbAogICogICAgICBlbnZva2UgdGhlIGtpbGwgcm91dGluZXMgZm9yIHBlbmRpbmcgc29ja3MuCiAgKj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09Ki8KIApAQCAtMTEyNSw3ICsxMTI1LDcgQEAKICAqCiAgKglUaGlzIGlzIGEgZnVuY3Rpb24gd2hpY2ggcGVyZm9ybXMgYWN0dWFsIGtpbGxpbmcKICAqICAgICAgb2YgdGhlIHNvY2suICBJdCByZWxlYXNlcyBzb2NrZXQgcmVzb3VyY2VzLAotICogICAgICBhbmQgdW5saW5rcyB0aGUgc29jayBmcm9tIHRoZSBkcml2ZXIuIAorICogICAgICBhbmQgdW5saW5rcyB0aGUgc29jayBmcm9tIHRoZSBkcml2ZXIuCiAgKj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09Ki8KIAogc3RhdGljIHZvaWQgd2FucGlwZV9raWxsX3NvY2tfdGltZXIgKHVuc2lnbmVkIGxvbmcgZGF0YSkKQEAgLTExMzksMTMgKzExMzksMTMgQEAKIAogCS8qIFRoaXMgZnVuY3Rpb24gY2FuIGJlIGNhbGxlZCBmcm9tIGludGVycnVwdC4gV2UgbXVzdCB1c2UKIAkgKiBhcHByb3ByaWF0ZSBsb2NrcyAqLwotCQorCiAJaWYgKHRlc3RfYml0KDEsJndhbnBpcGVfdHhfY3JpdGljYWwpKXsKIAkJc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AotICAgICAgICAgICAgICAgICAqIFRoaXMgaXMgdXNlZCBieSBQVkMgbW9zdGx5Ci0gICAgICAgICAgICAgICAgICovCisJCS8qIEJpbmQgYSBzb2NrZXQgdG8gYSBpbnRlcmZhY2UgbmFtZQorCQkgKiBUaGlzIGlzIHVzZWQgYnkgUFZDIG1vc3RseQorCQkgKi8KIAkJc3RybGNweShuYW1lLHNsbC0+c2xsX2RldmljZSxzaXplb2YobmFtZSkpOwogCQlkZXYgPSBkZXZfZ2V0X2J5X25hbWUobmFtZSk7CiAJCWlmIChkZXYgPT0gTlVMTCl7CkBAIC0xNDE5LDggKzE0MTksOCBAQAogCiAvKj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PQogICogZ2V0X2F0b21pY19kZXZpY2UKLSAqCQotICoJU2V0cyBhIGJpdCBhdG9taWNhbGx5IHdoaWNoIGluZGljYXRlcyB0aGF0IAorICoKKyAqCVNldHMgYSBiaXQgYXRvbWljYWxseSB3aGljaCBpbmRpY2F0ZXMgdGhhdAogICogICAgICB0aGUgaW50ZXJmYWNlIGlzIHRha2VuLiBUaGlzIGF2b2lkcyByYWNlIGNvbmRpdGlvbnMuCiAgKj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09Ki8KIApAQCAtMTQzNiw3ICsxNDM2LDcgQEAKIAogLyo9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KICAqIGNoZWNrX2RldgotICoJCisgKgogICogIAlDaGVjayB0aGF0IGRldmljZSBuYW1lIGJlbG9uZ3MgdG8gYSBwYXJ0aWN1bGFyIGNhcmQuCiAgKj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09Ki8KIApAQCAtMTQ0Niw4ICsxNDQ2LDggQEAKIAogCWZvciAodG1wX2RldiA9IGNhcmQtP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AJc29ja19yZWN2X3RpbWVzdGFtcChtc2csIHNrLCBza2IpOwotCQorCiAJaWYgKG1zZy0+bXNnX25hbWUpCiAJCW1lbWNweShtc2ctPm1zZ19uYW1lLCBza2ItPmNiLCBtc2ctPm1zZ19uYW1lbGVuKTsKIApAQCAtMTYyMywxMyArMTYyMywxMyBAQAogCiAvKj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PQogICogIHdhbnBpcGVfd2FrZXVwX2RyaXZlcgotICoJCisgKgogICogCUlmIHNvY2tldCByZWNlaXZlIGJ1ZmZlciBpcyBmdWxsIGFuZCBkcml2ZXIgY2Fubm90CiAgKiAgICAgIHBhc3MgZGF0YSB1cCB0aGUgc29jaywgaXQgc2V0cyBhIHBhY2tldF9ibG9jayBmbGFnLgotICogICAgICBUaGlzIGZ1bmN0aW9uIGNoZWNrIHRoYXQgZmxhZyBhbmQgaWYgc29jayByZWNlaXZlIAotICogICAgICBxdWV1ZSBoYXMgcm9vbSBpdCBraWNrcyB0aGUgZHJpdmVyIEJIIGhhbmRsZXIuIAorICogICAgICBUaGlzIGZ1bmN0aW9uIGNoZWNrIHRoYXQgZmxhZyBhbmQgaWYgc29jayByZWNlaXZlCisgKiAgICAgIHF1ZXVlIGhhcyByb29tIGl0IGtpY2tzIHRoZSBkcml2ZXIgQkggaGFuZGxlci4KICAqCi0gKiAJVGhpcyB3YXksIGRyaXZlciBkb2Vzbid0IGhhdmUgdG8gcG9sbCB0aGUgc29jayAKKyAqIAlUaGlzIHdheSwgZHJpdmVyIGRvZXNuJ3QgaGF2ZSB0byBwb2xsIHRoZSBzb2NrCiAgKiAgICAgIHJlY2VpdmUgcXVldWUuCiAgKj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09Ki8KIApAQCAtMTY0Niw4ICsxNjQ2LDggQEAKIAogCWlmICgoY2hhbiA9IGRldi0+cHJpdikgPT0gTlVMTCkKIAkJcmV0dXJuOwotCQotCWlmIChhdG9taWNfcmVhZCgmY2hhbi0+cmVjZWl2ZV9ibG9jaykpeyAgCisKKwlpZiAoYXRvbWljX3JlYWQoJmNoYW4tPnJlY2VpdmVfYmxvY2spKXsKIAkJaWYgKGF0b21pY19yZWFkKCZzay0+c2tfcm1lbV9hbGxvYykgPAogCQkgICAgKCh1bnNpZ25lZClzay0+c2tfcmN2YnVmICogMC45KSkgewogCQkJcHJpbnRrKEtFUk5fSU5GTyAid2Fuc29jazogUXVldWluZyB0YXNrIGZvciB3YW5waXBlXG4iKTsKQEAgLTE2NTUsMTMgKzE2NTUsMTMgQEAKIAkJCXdhbnBpcGVfcXVldWVfdHEoJmNoYW4tPndhbnBpcGVfdGFzayk7CiAJCQl3YW5waXBlX21hcmtfYmgoKTsKIAkJfQotCX0JCi19CQorCX0KK30KIAogLyo9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KICAqICB3YW5waXBlX2dldG5hbWUKLSAqCQotICogCUkgZG9uJ3Qga25vdyB3aGF0IHRvIGRvIHdpdGggdGhpcyB5ZXQuIAorICoKKyAqIAlJIGRvbid0IGtub3cgd2hhdCB0byBkbyB3aXRoIHRoaXMgeWV0LgogICogICAgICBVc2VyIGNhbiB1c2UgdGhpcyBmdW5jdGlvbiB0byBnZXQgc29jayBhZGRyZXNzCiAgKiAgICAgIGluZm9ybWF0aW9uLiBOb3QgdmVyeSB1c2VmdWwgZm9yIFNhbmdvbWEncyBwdXJwb3Nlcy4KICAqPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0qLwpAQCAtMTY4NywxNyArMTY4NywxNyBAQAogCQlzbGwtPnNsbF9oYWxlbiA9IDA7CiAJfQogCSp1YWRkcl9sZW4gPSBzaXplb2YoKnNsbCk7Ci0JCisKIAlkZXZfcHV0KGRldik7Ci0JCisKIAlyZXR1cm4gMDsKIH0KIAogLyo9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KICAqICB3YW5waXBlX25vdGlmaWVyCi0gKgkKKyAqCiAgKglJZiBkcml2ZXIgdHVybnMgb2ZmIG5ldHdvcmsgaW50ZXJmYWNlLCB0aGlzIGZ1bmN0aW9uCi0gKiAgICAgIHdpbGwgYmUgZW52b2tlZC4gQ3VycmVudGx5IEkgdHJlYXRlIGl0IGFzIGEgCisgKiAgICAgIHdpbGwgYmUgZW52b2tlZC4gQ3VycmVudGx5IEkgdHJlYXRlIGl0IGFzIGEKICAqICAgICAgY2FsbCBkaXNjb25uZWN0LiBNb3JlIHRob3VnaHQgc2hvdWxkIGdvIGludG8gdGhpcwogICogICAgICBmdW5jdGlvbi4KICAqCkBAIC0xNzE4LDcgKzE3MTgsNyBAQAogCQkJY29udGludWU7CiAJCWlmIChkZXYgPT0gTlVMTCkKIAkJCWNvbnRpbnVlOwotCQkKKwogCQlzd2l0Y2ggKG1zZykgewogCQljYXNlIE5FVERFVl9ET1dOOgogCQljYXNlIE5FVERFVl9VTlJFR0lTVEVSOgpAQCAtMTczMiw3ICsxNzMyLDcgQEAKIAogCQkJCWlmIChtc2cgPT0gTkVUREVWX1VOUkVHSVNURVIpIHsKIAkJCQkJcHJpbnRrKEtFUk5fSU5GTyAid2Fuc29jazogVW5yZWdpc3RlcmluZyBEZXZpY2U6ICVzXG4iLAotCQkJCQkJIAkgIGRldi0+bmFtZSk7CisJCQkJCQkJICBkZXYtPm5hbWUpOwogCQkJCQl3YW5waXBlX3VubGlua19kcml2ZXIoc2spOwogCQkJCQlzay0+c2tfYm91bmRfZGV2X2lmID0gMDsKIAkJCQl9CkBAIC0xNzUzLDcgKzE3NTMsNyBAQAogCiAvKj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PQogICogIHdhbnBpcGVfaW9jdGwKLSAqCQorICoKICAqIAlFeGVj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GVudHMgb2Ygc29ja2V0IE1CT1ggdG8gdGhlIHVzZXIuCiAgKj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09Ki8KIApAQCAtMTk3NCw3ICsxOTc0LDcgQEAKIAlpZiAoKGVycj1wdXRfdXNlcihtYm94X3B0ci0+Y21kLnJlc3VsdCwgJnVzcl9kYXRhLT5oZHIucmVzdWx0KSkpCiAJCXJldHVybiBlcnI7CiAJaWYgKChlcnI9cHV0X3VzZXIobWJveF9wdHItPmNtZC5sY24sICZ1c3JfZGF0YS0+aGRyLmxjbikpKQotCQlyZXR1cm4gZXJyOwkKKwkJcmV0dXJuIGVycjsKIAogCWlmIChtYm94X3B0ci0+Y21kLmxlbmd0aCA+IDApewogCQlpZiAobWJveF9wdHItPmNtZC5sZW5ndGggPiBYMjVfTUFYX0RBVEEpCkBAIC0xOTg2LDEzICsxOTg2LDEzIEBACiAJCX0KIAl9CiAJcmV0dXJuIDA7Ci19IAorfQogCiAvKj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PQogICogIHNldF9pb2N0bF9jbWQKLSAqCQorICoKICAqCUJlZm9yZSBjb21tYW5kIGNhbiBiZSBleGVjdXRlLCBzb2NrZXQgTUJPWCBtdXN0Ci0gKiAgICAgIGJlIGNyZWF0ZWQsIGFuZCBpbml0aWFsaXplZCB3aXRoIHVzZXIgZGF0YS4JCisgKiAgICAgIGJlIGNyZWF0ZWQsIGFuZCBpbml0aWFsaXplZCB3aXRoIHVzZXIgZGF0YS4KICAqPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0qLwogCiBzdGF0aWMgaW50IHNldF9pb2N0bF9jbWQgKHN0cnVjdCBzb2NrICpzaywgdm9pZCAqYXJnKQpAQCAtMjAwOCw3ICsyMDA4LDcgQEAKIAkJCXJldHVybiAtRU5PREVWOwogCiAJCWRld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gPSB7CisJCS5lbmNyID0geworCQkJLmJsb2NrYml0cyA9IDEyOCwKKwkJCS5kZWZrZXliaXRzID0gMTI4LAorCQl9CisJfSwKIAotICAgICAgICAuZGVzYyA9IHsKLSAgICAgICAgICAgICAgICAuc2FkYl9hbGdfaWQgPSBTQURCX1hfRUFMR19TRVJQRU5UQ0JDLAotICAgICAgICAgICAgICAgIC5zYWRiX2FsZ19pdmxlbiA9IDgsCi0gICAgICAgICAgICAgICAgLnNhZGJfYWxnX21pbmJpdHMgPSAxMjgsCi0gICAgICAgICAgICAgICAgLnNhZGJfYWxnX21heGJpdHMgPSAyNTYsCi0gICAgICAgIH0KKwkuZGVzYyA9IHsKKwkJLnNhZGJfYWxnX2lkID0gU0FEQl9YX0VBTEdfU0VSUEVOVENCQywKKwkJLnNhZGJfYWxnX2l2bGVuID0gOCwKKwkJLnNhZGJfYWxnX21pbmJpdHMgPSAxMjgsCisJCS5zYWRiX2FsZ19tYXhiaXRzID0gMjU2LAorCX0KIH0sCiB7Ci0gICAgICAgIC5uYW1lID0gImNiYyh0d29maXNoKSIsCi0gICAgICAgIC5jb21wYXQgPSAidHdvZmlzaCIsCi0gICAgICAgICAgICAgICAgIAotICAgICAgICAudWluZm8gPSB7Ci0gICAgICAgICAgICAgICAgLmVuY3IgPSB7Ci0gICAgICAgICAgICAgICAgICAgICAgICAuYmxvY2tiaXRzID0gMTI4LAotICAgICAgICAgICAgICAgICAgICAgICAgLmRlZmtleWJpdHMgPSAxMjgsCi0gICAgICAgICAgICAgICAgfQotICAgICAgICB9LAorCS5uYW1lID0gImNiYyhjYW1lbGxpYSkiLAogCi0gICAgICAgIC5kZXNjID0gewotICAgICAgICAgICAgICAgIC5zYWRiX2FsZ19pZCA9IFNBREJfWF9FQUxHX1RXT0ZJU0hDQkMsCi0gICAgICAgICAgICAgICAgLnNhZGJfYWxnX2l2bGVuID0gOCwKLSAgICAgICAgICAgICAgICAuc2FkYl9hbGdfbWluYml0cyA9IDEyOCwKLSAgICA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SApLCAgICAgICAgICAgICAgICAgIFwKIAlAc2V0IC1lOyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBcCiAJJChlY2hvLWNtZCkgJChjbWRfJCgxKSk7ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgXApAQCAtMTc2LDEwICsxNzcsOSBAQAogCXJtIC1mICQoZGVwZmlsZSk7ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFwKIAltdiAtZiAkKGRvdC10YXJnZXQpLnRtcCAkKGRvdC10YXJnZXQpLmNtZCkKIAotIyBXaWxsIGNoZWNrIGlmICQoY21kX2ZvbykgY2hhbmdlZCwgb3IgYW55IG9mIHRoZSBwcmVyZXF1aXNpdGVzIGNoYW5nZWQsCi0jIGFuZCBpZiBzbyB3aWxsIGV4ZWN1dGUgJChydWxlX2ZvbykuCiAjIFVzYWdlOiAkKGNhbGwgaWZfY2hhbmdlZF9ydWxlLGZvbykKLSMKKyMgV2lsbCBjaGVjayBpZiAkKGNtZF9mb28pIG9yIGFueSBvZiB0aGUgcHJlcmVxdWlzaXRlcyBjaGFuZ2VkLAorIyBhbmQgaWYgc28gd2lsbCBleGVjdXRlICQocnVsZV9mb28pLgogaWZfY2hhbmdlZF9ydWxlID0gJChpZiAkKHN0cmlwICQoYW55LXByZXJlcSkgJChhcmctY2hlY2spICksICAgICAgICAgICAgICAgICBcCiAJQHNldCAtZTsgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgXAogCSQocnVsZV8kKDEpKSkKZGlmZiAtLWdpdCBhL3NjcmlwdHMva2NvbmZpZy9xY29uZi5jYyBiL3NjcmlwdHMva2NvbmZpZy9xY29uZi5jYwppbmRleCBjMGFlMGE3Li41MTJjMmY1IDEwMDY0NAotLS0gYS9zY3JpcHRzL2tjb25maWcvcWNvbmYuY2MKKys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3N7J3BhcmFtZXRlcnR5cGVzJ317JHBhcmFtZXRlcn07CkBAIC0xNDMzLDcgKzE0NDMsNyBAQAogCX0gZWxzaWYgKCRhcmcgPX4gbS9cKC4qXCovKSB7CiAJICAgICMgcG9pbnRlci10by1mdW5jdGlvbgogCSAgICAkYXJnID1+IHRyLyMvLC87Ci0JICAgICRhcmcgPX4gbS9bXlwoXStcKFwqKFteXCldKylcKS87CisJICAgICRhcmcgPX4gbS9bXlwoXStcKFwqXHMqKFteXCldKylcKS87CiAJICAgICRwYXJhbSA9ICQxOwogCSAgICAkdHlwZSA9ICRhcmc7CiAJICAgICR0eXBlID1+IHMvKFteXChdK1woXCopJHBhcmFtLyQxLzsKQEAgLTE1MzYsNyArMTU0Niw3IEBACiAgICAgJHByb3RvdHlwZSA9fiBzL15fX2Fsd2F5c19pbmxpbmUgKy8vOwogICAgICRwcm90b3R5cGUgPX4gcy9ebm9pbmxpbmUgKy8vOwogICAgICRwcm90b3R5cGUgPX4gcy9fX2RldmluaXQgKy8vOwotICAgICRwcm90b3R5cGUgPX4gcy9eI2RlZmluZSArLy87ICNhayBhZGRlZAorICAgICRwcm90b3R5cGUgPX4gcy9eI2RlZmluZVxzKy8vOyAjYWsgYWRkZWQKICAgICAkcHJvdG90eXBlID1+IHMvX19hdHRyaWJ1dGVfXyBcKFwoW2EteixdKlwpXCkvLzsKIAogICAgICMgWWVzLCB0aGlzIHRydWx5IGlzIHZpbGUuICBXZSBhcmUgbG9va2luZyBmb3I6CkBAIC0xNTcwLDcgKzE1ODAsOCBAQAogCSRwcm90b3R5cGUgPX4gbS9eKFx3K1xzK1x3K1xzK1x3KylccysoW2EtekEtWjAtOV9+Ol0rKVxzKlwoKFteXHtdKilcKS8gfHwKIAkkcHJvdG90eXBlID1+IG0vXihcdytccytcdytccytcdytccypcKilccyooW2EtekEtWjAtOV9+Ol0rKVxzKlwoKFteXHtdKilcKS8gfHwKIAkkcHJvdG90eXBlID1+IG0vXihcdytccytcdytccytcdytccyt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RFVMRV9QQVJNX0RFU0MoZW5hYmxlLCAiRW5hYmxlICIgQ0FSRF9OQU1FICIgc291bmRjYXJkLiIpOworCitNT0RVTEVfQVVUSE9SKCJMZXZlbnQgR3VlbmRvZ2R1LCBUb2JpYXMgR2VocmlnLCBNYXR0aGlhcyBLb2VuaWciKTsKK01PRFVMRV9ERVNDUklQVElPTigiTWlkaW1hbiBQb3J0bWFuMng0Iik7CitNT0RVTEVfTElDRU5TRSgiR1BMIik7CitNT0RVTEVfU1VQUE9SVEVEX0RFVklDRSgie3tNaWRpbWFuLFBvcnRtYW4yeDR9fSIpOworCisvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqCisgKiBDaGlwIHNwZWNpZmljCisgKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqLworI2RlZmluZSBQT1JUTUFOX05VTV9JTlBVVF9QT1JUUyAyCisjZGVmaW5lIFBPUlRNQU5fTlVNX09VVFBVVF9QT1JUUyA0CisKK3N0cnVjdCBwb3J0bWFuIHsKKwlzcGlubG9ja190IHJlZ19sb2NrOworCXN0cnVjdCBzbmRfY2FyZCAqY2FyZDsKKwlzdHJ1Y3Qgc25kX3Jhd21pZGkgKnJtaWRpOworCXN0cnVjdCBwYXJkZXZpY2UgKnBhcmRldjsKKwlpbnQgcGFyZGV2X2NsYWltZWQ7CisKKwlpbnQgb3Blbl9jb3VudDsKKwlpbnQgbW9kZVtQT1JUTUFOX05VTV9JTlBVVF9QT1JUU107CisJc3RydWN0IHNuZF9yYXdtaWRpX3N1YnN0cmVhbSAqbWlkaV9pbnB1dFtQT1JUTUFOX05VTV9JTlBVVF9QT1JUU107Cit9OworCitzdGF0aWMgaW50IHBvcnRtYW5fZnJlZShzdHJ1Y3QgcG9ydG1hbiAqcG0pCit7CisJa2ZyZWUocG0pOworCXJldHVybiAwOworfQorCitzdGF0aWMgaW50IF9fZGV2aW5pdCBwb3J0bWFuX2NyZWF0ZShzdHJ1Y3Qgc25kX2NhcmQgKmNhcmQsIAorCQkJCSAgICBzdHJ1Y3QgcGFyZGV2aWNlICpwYXJkZXYsIAorCQkJCSAgICBzdHJ1Y3QgcG9ydG1hbiAqKnJjaGlwKQoreworCXN0cnVjdCBwb3J0bWFuICpwbTsKKworCSpyY2hpcCA9IE5VTEw7CisKKwlwbSA9IGt6YWxsb2Moc2l6ZW9mKHN0cnVjdCBwb3J0bWFuKSwgR0ZQX0tFUk5FTCk7CisJaWYgKHBtID09IE5VTEwpIAorCQlyZXR1cm4gLUVOT01FTTsKKworCS8qIEluaXQgY2hpcCBzcGVjaWZpYyBkYXRhICovCisJc3Bpbl9sb2NrX2luaXQoJnBtLT5yZWdfbG9jayk7CisJcG0tPmNhcmQgPSBjYXJkOworCXBtLT5wYXJkZXYgPSBwYXJkZXY7CisKKwkqcmNoaXAgPSBwbTsKKworCXJldHVybiAwOworfQorCisvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqCisgKiBIVyByZWxhdGVkIGNvbnN0YW50cworICoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKi8KKworLyogU3RhbmRhcmQgUEMgcGFyYWxsZWwgcG9ydCBzdGF0dXMgcmVnaXN0ZXIgZXF1YXRlcy4gKi8KKyNkZWZpbmUJUFBfU1RBVF9CU1kgICAJMHg4MAkvKiBCdXN5IHN0YXR1cy4gIEludmVydGVkLiAqLworI2RlZmluZQlQUF9TVEFUX0FDSyAgIAkweDQwCS8qIEFja25vd2xlZGdlLiAgTm9uLUludmVydGVkLiAqLworI2RlZmluZQlQUF9TVEFUX1BPVVQgIAkweDIwCS8qIFBhcGVyIE91dC4gICAgTm9uLUludmVydGVkLiAqLworI2RlZmluZQlQUF9TVEFUX1NFTCAgIAkweDEwCS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KiBiZXR3ZWVuIHNldmVyYWwgZnVuY3Rpb25zLiAgRGVwZW5kaW5nIG9uIHdoaWNoIDJ4NCAicmVnaXN0ZXIiIGlzCisgKiBjdXJyZW50bHkgc2VsZWN0ZWQgKGIxLi5iMyksIHRoZSBCVVNZIGFuZCBTRUxFQ1QgbGluZXMgYXJlCisgKiBhc3NpZ25lZCBhcyBmb2xsb3dzOgorICoKKyAqICAgU0VMRUNUIExJTkU6ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIEEzIEEyIEExCisgKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAtLS0tLS0tLQorICovCisjZGVmaW5lCVJYQVZBSUwJCVBQX1NUQVRfU0VMCS8qIFJ4IEF2YWlsYWJsZSwgY2hhbm5lbCAwLiAgIDAgMCAwICovCisvLyAgUlhBVkFJTDEgICAgUFBfU1RBVF9TRUwgICAgICAgICAgICAgLyogUnggQXZhaWxhYmxlLCBjaGFubmVsIDEuICAgMCAwIDEgKi8KKyNkZWZpbmUJU1lOQ19TVEFUCVBQX1NUQVRfU0VMCS8qIFJlc2VydmVkIC0gU3luYyBTdGF0dXMuICAgIDAgMSAwICovCisvLyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLyogUmVzZXJ2ZWQuICAgICAgICAgICAgICAgICAgMCAxIDEgKi8KKyNkZWZpbmUJVFhFTVBUWQkJUFBfU1RBVF9TRUwJLyogVHggRW1wdHksIGNoYW5uZWwgMC4gICAgICAgMSAwIDAgKi8KKy8vICAgICAgVFhFTVBUWTEgICAgICAgIFBQX1NUQVRfU0VMICAgICAvKiBUeCBFbXB0eSwgY2hhbm5lbCAxLiAgICAgICAxIDAgMSAqLworLy8gIFRYRU1QVFkyICAgIFBQX1NUQVRfU0VMICAgICAgICAgICAgIC8qIFR4IEVtcHR5LCBjaGFubmVsIDIuICAgICAgIDEgMSAwICovCisvLyAgVFhFTVBUWTMgICAgUFBfU1RBVF9TRUwgICAgICAgICAgICAgLyogVHggRW1wdHksIGNoYW5uZWwgMy4gICAgICAgMSAxIDEgKi8KKworLyogICBCVVNZIExJTkU6ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgQTMgQTIgQTEKKyAqICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIC0tLS0tLS0tCisgKi8KKyNkZWZpbmUJUlhEQVRBCQlQUF9TVEFUX0JTWQkvKiBSeCBJbnB1dCBEYXRhLCBjaGFubmVsIDAuICAwIDAgMCAqLworLy8gICAgICBSWERBVEExICAgICAgICAgUFBfU1RBVF9CU1kgICAgIC8qIFJ4IElucHV0IERhdGEsIGNoYW5uZWwgMS4gIDAgMCAxICovCisjZGVmaW5lCVNZTkNfREFUQSAgICAgICBQUF9TVEFUX0JTWQkvKiBSZXNlcnZlZCAtIFN5bmMgRGF0YS4gICAgICAwIDEgMCAqLworCQkJCQkvKiBSZXNlcnZlZC4gICAgICAgICAgICAgICAgICAwIDEgMSAqLworI2RlZmluZQlEQVRBX0VDSE8gICAgICAgUFBfU1RBVF9CU1kJLyogUGFyYWxsZWwgUG9ydCBEYXRhIEVjaG8uICAgMSAwIDAgKi8KKyNkZWZpbmUJQTBfRUNITyAgICAgICAgIFBQX1NUQVRfQlNZCS8qIEFkZHJlc3MgMCBFY2hvLiAgICAgICAgICAgIDEgMCAxICovCisjZGVmaW5lCUExX0VDSE8gICAgICAgICBQUF9TVEFUX0JTWQkvKiBBZGRyZXNzIDEgRWNoby4gICAgICAgICAgICAxIDEgMCAqLworI2RlZmluZQlBMl9FQ0hPICAgICAgICAgUFBfU1RBVF9CU1kJLyogQWRkcmVzcyAyIEVjaG8uICAgICAgICAgICAgMSAxIDEgKi8KKworI2RlZmluZSBQT1JUTUFOMlg0X01PREVfSU5QVVRfVFJJR0dFUkVECSAwe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ZmYuICovCisKKwkvKiBJZiBQQ1AgY2hhbm5lbCdzIFR4RW1wdHkgaXMgc2V0IChUeEVtcHR5IGlzIHJlYWQgdGhyb3VnaCB0aGUgUFAKKwkgKiBTdGF0dXMgUmVnaXN0ZXIpLCB0aGVuIGdvIHdyaXRlIGRhdGEuICBFbHNlIGdvIGJhY2sgYW5kIHdhaXQuCisJICovCisJLyogOSAqLworCWlmICgocGFycG9ydF9yZWFkX3N0YXR1cyhwKSAmIFRYRU1QVFkpID09IDApCisJCXJldHVybiAyOworCisJLyogUmV0dXJuIE9LIHN0YXR1cy4gKi8KKwlyZXR1cm4gMDsKK30KKworc3RhdGljIGludCBwb3J0bWFuX2RldmljZV9pbml0KHN0cnVjdCBwb3J0bWFuICpwbSkKK3sKKwlwb3J0bWFuX2ZsdXNoX2lucHV0KHBtLCAwKTsKKwlwb3J0bWFuX2ZsdXNoX2lucHV0KHBtLCAxKTsKKworCXJldHVybiAwOworfQorCisvKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqCisgKiBSYXdtaWRpCisgKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqLworc3RhdGljIGludCBzbmRfcG9ydG1hbl9taWRpX29wZW4oc3RydWN0IHNuZF9yYXdtaWRpX3N1YnN0cmVhbSAqc3Vic3RyZWFtKQoreworCXJldHVybiAwOworfQorCitzdGF0aWMgaW50IHNuZF9wb3J0bWFuX21pZGlfY2xvc2Uoc3RydWN0IHNuZF9yYXdtaWRpX3N1YnN0cmVhbSAqc3Vic3RyZWFtKQoreworCXJldHVybiAwOworfQorCitzdGF0aWMgdm9pZCBzbmRfcG9ydG1hbl9taWRpX2lucHV0X3RyaWdnZXIoc3RydWN0IHNuZF9yYXdtaWRpX3N1YnN0cmVhbSAqc3Vic3RyZWFtLAorCQkJCQkgICBpbnQgdXApCit7CisJc3RydWN0IH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2ZXIgPSB7CisJLm5hbWUgICA9ICJwb3J0bWFuMng0IiwKKwkuYXR0YWNoID0gc25kX3BvcnRtYW5fYXR0YWNoLAorCS5kZXRhY2ggPSBzbmRfcG9ydG1hbl9kZXRhY2gKK307CisKKy8qKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioKKyAqIHBsYXRmb3JtIHN0dWZmCisgKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqLworc3RhdGljIHZvaWQgc25kX3BvcnRtYW5fY2FyZF9wcml2YXRlX2ZyZWUoc3RydWN0IHNuZF9jYXJkICpjYXJkKQoreworCXN0cnVjdCBwb3J0bWFuICpwbSA9IGNhcmQtPnByaXZhdGVfZGF0YTsKKwlzdHJ1Y3QgcGFyZGV2aWNlICpwYXJkZXYgPSBwbS0+cGFyZGV2OworCisJaWYgKHBhcmRldikgeworCQlpZiAocG0tPnBhcmRldl9jbGFpbWVkKQorCQkJcGFycG9ydF9yZWxlYXNlKHBhcmRldik7CisJCXBhcnBvcnRfdW5yZWdpc3Rlcl9kZXZpY2UocGFyZGV2KTsKKwl9CisKKwlwb3J0bWFuX2ZyZWUocG0pOworfQorCitzdGF0aWMgaW50IF9fZGV2aW5pdCBzbmRfcG9ydG1hbl9wcm9iZShzdHJ1Y3QgcGxhdGZvcm1fZGV2aWNlICpwZGV2KQoreworCXN0cnVjdCBwYXJkZXZpY2UgKnBhcmRldjsKKwlzdHJ1Y3QgcGFycG9ydCAqcDsKKwlpbnQgZGV2ID0gcGRldi0+aWQ7CisJc3RydWN0IHNuZF9jYXJkICpjYXJkID0gTlVMTDsKKwlzdHJ1Y3QgcG9ydG1hbiAqcG0gPSBOVUxMOworCWludCBlcnI7CisKKwlwID0gcGxhdGZvcm1fZ2V0X2RydmRhdGEocGRldik7CisJcGxhdGZvcm1fc2V0X2RydmRhdGEocGRldiwgTl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kpIDwgMCkgeworCQlzbmRfcHJpbnRkKCJDYW5ub3QgcmVnaXN0ZXIgY2FyZFxuIik7CisJCWdvdG8gX19lcnI7CisJfQorCisJc25kX3ByaW50ayhLRVJOX0lORk8gIlBvcnRtYW4gMng0IG9uIDB4JWx4XG4iLCBwLT5iYXNlKTsKKwlyZXR1cm4gMDsKKworX19lcnI6CisJc25kX2NhcmRfZnJlZShjYXJkKTsKKwlyZXR1cm4gZXJyOworfQorCitzdGF0aWMgaW50IF9fZGV2ZXhpdCBzbmRfcG9ydG1hbl9yZW1vdmUoc3RydWN0IHBsYXRmb3JtX2RldmljZSAqcGRldikKK3sKKwlzdHJ1Y3Qgc25kX2NhcmQgKmNhcmQgPSBwbGF0Zm9ybV9nZXRfZHJ2ZGF0YShwZGV2KTsKKworCWlmIChjYXJkKQorCQlzbmRfY2FyZF9mcmVlKGNhcmQpOworCisJcmV0dXJuIDA7Cit9CisKKworc3RhdGljIHN0cnVjdCBwbGF0Zm9ybV9kcml2ZXIgc25kX3BvcnRtYW5fZHJpdmVyID0geworCS5wcm9iZSAgPSBzbmRfcG9ydG1hbl9wcm9iZSwKKwkucmVtb3ZlID0gX19kZXZleGl0X3Aoc25kX3BvcnRtYW5fcmVtb3ZlKSwKKwkuZHJpdmVyID0geworCQkubmFtZSA9IFBMQVRGT1JNX0RSSVZFUgorCX0KK307CisKKy8qKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioKKyAqIG1vZHVsZSBpbml0IHN0dWZmCisgKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqLworc3RhdGljIHZvaWQgX19pbml0X29yX21vZHVsZSBzbmRfcG9ydG1hbl91bnJlZ2lzdGVyX2FsbCh2b2lkKQoreworCWludCBpOworCisJZm9yIChpID0gMDsgaSA8IFNORFJWX0NBUkRTOyArK2kpIHsKKwkJaWYgKHBsY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AgICAgICAgMHgwMywKK307CisKK3N0YXRpYyBoZGFfbmlkX3Qgc3RhYzkyNXhfbXV4X25pZHNbMV0gPSB7CisgICAgICAgIDB4MGYsCit9OworCitzdGF0aWMgaGRhX25pZF90IHN0YWM5MjV4X2RhY19uaWRzWzFdID0geworICAgICAgICAweDAyLAorfTsKKwogc3RhdGljIGhkYV9uaWRfdCBzdGFjOTIyeF9hZGNfbmlkc1syXSA9IHsKICAgICAgICAgMHgwNiwgMHgwNywKIH07CkBAIC0xMzEsMTEgKzE3MiwyMCBAQAogICAgICAgICAweDE5LCAweDFhCiB9OwogCitzdGF0aWMgaGRhX25pZF90IHN0YWM5MjA1X2RtaWNfbmlkc1szXSA9IHsKKyAgICAgICAgMHgxNywgMHgxOCwgMAorfTsKKwogc3RhdGljIGhkYV9uaWRfdCBzdGFjOTIwMF9waW5fbmlkc1s4XSA9IHsKIAkweDA4LCAweDA5LCAweDBkLCAweDBlLCAKIAkweDBmLCAweDEwLCAweDExLCAweDEyLAogfTsKIAorc3RhdGljIGhkYV9uaWRfdCBzdGFjOTI1eF9waW5fbmlkc1s4XSA9IHsKKwkweDA3LCAweDA4LCAweDBhLCAweDBiLCAKKwkweDBjLCAweDBkLCAweDEwLCAweDExLAorfTsKKwogc3RhdGljIGhkYV9uaWRfdCBzdGFjOTIyeF9waW5fbmlkc1sxMF0gPSB7CiAJMHgwYSwgMHgwYiwgMHgwYywgMHgwZCwgMHgwZSwKIAkweDBmLCAweDEwLCAweDExLCAweDE1LCAweDFiLApAQCAtMTU0LDYgKzIwNCwzNCBAQAogCQogfTsKIAorc3RhdGljIGludCBzdGFjOTJ4eF9kbXV4X2VudW1faW5mbyhzdHJ1Y3Qgc25kX2tjb250cm9sICprY29udHJvbCwKKwkJCQkgICBzdHJ1Y3Qgc25kX2N0bF9lbGVtX2luZm8gKnVpbmZvKQoreworCXN0cnVjdCBoZGFfY29kZWMgKmNvZGVjID0gc25kX2tjb250cm9sX2NoaXAoa2NvbnRyb2wpOwor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IGNvZGVjICAgICovCisvKiAyMDA2LTAzLTE0ICBMeWRpYSBXYW5nICBNb2RpZnkgaGFyZCBjb2RlIGZvciBzb21lIHBpbiB3aWRnZXQgbmlkICAgICAgICAgICovCisvKiAyMDA2LTA4LTAyICBMeWRpYSBXYW5nICBBZGQgc3VwcG9ydCB0byBWVDE3MDkgY29kZWMgICAgICAgICAgICAgICAgICAgICAgICovCisvKiAyMDA2LTA5LTA4ICBMeWRpYSBXYW5nICBGaXggaW50ZXJuYWwgbG9vcGJhY2sgcmVjb3JkaW5nIHNvdXJjZSBzZWxlY3QgYnVnICovCisvKiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICovCisvKiAqICogKiAqICogKiAqICogKiAqICogKiAqICogKiAqICogKiAqICogKiAqICogKiAqICogKiAqICogKiAqICogKiAqICogKiAqICovCisKKworI2luY2x1ZGUgPHNvdW5kL2RyaXZlci5oPgorI2luY2x1ZGUgPGxpbnV4L2luaXQuaD4KKyNpbmNsdWRlIDxsaW51eC9kZWxheS5oPgorI2luY2x1ZGUgPGxpbnV4L3NsYWIuaD4KKyNpbmNsdWRlIDxsaW51eC9wY2kuaD4KKyNpbmNsdWRlIDxzb3VuZC9jb3JlLmg+CisjaW5jbHVkZSAiaGRhX2NvZGVjLmgiCisjaW5jbHVkZSAiaGRhX2xvY2FsLmgiCisKKworLyogYW1wIHZhbHVlcyAqLworI2RlZmluZSBBTVBfVkFMX0lEWF9TSElGVAkxOQorI2RlZmluZSBBTVBfVkFMX0lEWF9NQVNLCSgweDBmPDwxOSkKKworI2RlZmluZSBOVU1fQ09OVFJPTF9BTExPQwkzMgorI2RlZmluZSBOVU1fVkVSQl9BTExPQwkJMzIKKworLyogUGluIFdpZGdldCBOSUQgKi8KKyNkZWZpbmUgVlQxNzA4X0hQX05JRAkJMHgxMworI2RlZmluZSBWVDE3MDhfRElHT1VUX05JRAkweDE0CisjZGVmaW5l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BQywgcmVnIHwgMHgwMTAwKTsKKwlyZWcgPSB3bTg3NTBfcmVhZF9yZWdfY2FjaGUoY29kZWMsIFdNODc1MF9SREFDKTsKKwl3bTg3NTBfd3JpdGUoY29kZWMsIFdNODc1MF9SREFDLCByZWcgfCAweDAxMDApOworCXJlZyA9IHdtODc1MF9yZWFkX3JlZ19jYWNoZShjb2RlYywgV004NzUwX0xPVVQxVik7CisJd204NzUwX3dyaXRlKGNvZGVjLCBXTTg3NTBfTE9VVDFWLCByZWcgfCAweDAxMDApOworCXJlZyA9IHdtODc1MF9yZWFkX3JlZ19jYWNoZShjb2RlYywgV004NzUwX1JPVVQxVik7CisJd204NzUwX3dyaXRlKGNvZGVjLCBXTTg3NTBfUk9VVDFWLCByZWcgfCAweDAxMDApOworCXJlZyA9IHdtODc1MF9yZWFkX3JlZ19jYWNoZShjb2RlYywgV004NzUwX0xPVVQyVik7CisJd204NzUwX3dyaXRlKGNvZGVjLCBXTTg3NTBfTE9VVDJWLCByZWcgfCAweDAxMDApOworCXJlZyA9IHdtODc1MF9yZWFkX3JlZ19jYWNoZShjb2RlYywgV004NzUwX1JPVVQyVik7CisJd204NzUwX3dyaXRlKGNvZGVjLCBXTTg3NTBfUk9VVDJWLCByZWcgfCAweDAxMDApOworCXJlZyA9IHdtODc1MF9yZWFkX3JlZ19jYWNoZShjb2RlYywgV004NzUwX0xJTlZPTCk7CisJd204NzUwX3dyaXRlKGNvZGVjLCBXTTg3NTBfTElOVk9MLCByZWcgfCAweDAxMDApOworCXJlZyA9IHdtODc1MF9yZWFkX3JlZ19jYWNoZShjb2RlYywgV004NzUwX1JJTlZPTCk7CisJd204NzUwX3dyaXRlKGNvZGVjLCBXTTg3NTBfUklOVk9MLCByZWcgfCAweDAxMDApOworCisJd204NzUwX2FkZF9jb250cm9scyhjb2RlYyk7CisJd204NzUwX2FkZF93aWRnZXRzKGNvZGVjKTsKKwlyZXQgPSBzbmRfc29jX3JlZ2lzdGVyX2NhcmQoc29jZGV2KT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wkJY29kZWMtPmh3X3dyaXRlID0gKGh3X3dyaXRlX3QpaTJjX21hc3Rlcl9zZW5kOworCQlyZXQgPSBpMmNfYWRkX2RyaXZlcigmd204NzUwX2kyY19kcml2ZXIpOworCQlpZiAocmV0ICE9IDApCisJCQlwcmludGsoS0VSTl9FUlIgImNhbid0IGFkZCBpMmMgZHJpdmVyIik7CisJfQorI2Vsc2UKKwkJLyogQWRkIG90aGVyIGludGVyZmFjZXMgaGVyZSAqLworI2VuZGlmCisKKwlyZXR1cm4gcmV0OworfQorCisvKgorICogVGhpcyBmdW5jdGlvbiBmb3JjZXMgYW55IGRlbGF5ZWQgd29yayB0byBiZSBxdWV1ZWQgYW5kIHJ1bi4KKyAqLworc3RhdGljIGludCBydW5fZGVsYXllZF93b3JrKHN0cnVjdCBkZWxheWVkX3dvcmsgKmR3b3JrKQoreworCWludCByZXQ7CisKKwkvKiBjYW5jZWwgYW55IHdvcmsgd2FpdGluZyB0byBiZSBxdWV1ZWQuICovCisJcmV0ID0gY2FuY2VsX2RlbGF5ZWRfd29yayhkd29yayk7CisKKwkvKiBpZiB0aGVyZSB3YXMgYW55IHdvcmsgd2FpdGluZyB0aGVuIHdlIHJ1biBpdCBub3cgYW5kCisJICogd2FpdCBmb3IgaXQncyBjb21wbGV0aW9uICovCisJaWYgKHJldCkgeworCQlzY2hlZHVsZV9kZWxheWVkX3dvcmsoZHdvcmssIDApOworCQlmbHVzaF9zY2hlZHVsZWRfd29yaygpOworCX0KKwlyZXR1cm4gcmV0OworfQorCisvKiBwb3dlciBkb3duIGNoaXAgKi8KK3N0YXRpYyBpbnQgd204NzUwX3JlbW92ZShzdHJ1Y3QgcGxhdGZvcm1fZGV2aWNlICpwZGV2KQoreworCXN0cnVjdCBzbmRfc29jX2RldmljZSAqc29jZGV2ID0gcGxhdGZvcm1fZ2V0X2RydmRhdGEocGRldik7CisJc3RydWN0IHNuZF9zb2NfY29kZWMgKmNvZGVjID0gc29jZGV2LT5jb2RlYzsKKworCWl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b3BfZGV2aWNlLmRldiwgU1BJVFpfU0NQX01VVEVfUik7CisJCWJyZWFrOworCWNhc2UgU1BJVFpfTElORToKKwkJLyogZW5hYmxlIGxpbmUgamFjaywgZGlzYWJsZSBtaWMgYmlhcyBhbmQgbXV0ZSBocCAqLworCQlzbmRfc29jX2RhcG1fc2V0X2VuZHBvaW50KGNvZGVjLCAiSGVhZHBob25lIEphY2siLCAwKTsKKwkJc25kX3NvY19kYXBtX3NldF9lbmRwb2ludChjb2RlYywgIkhlYWRzZXQgSmFjayIsIDApOworCQlzbmRfc29jX2RhcG1fc2V0X2VuZHBvaW50KGNvZGVjLCAiTWljIEphY2siLCAwKTsKKwkJc25kX3NvY19kYXBtX3NldF9lbmRwb2ludChjb2RlYywgIkxpbmUgSmFjayIsIDEpOworCQlyZXNldF9zY29vcF9ncGlvKCZzcGl0enNjb29wX2RldmljZS5kZXYsIFNQSVRaX1NDUF9NVVRFX0wpOworCQlyZXNldF9zY29vcF9ncGlvKCZzcGl0enNjb29wX2RldmljZS5kZXYsIFNQSVRaX1NDUF9NVVRFX1IpOworCQlicmVhazsKKwljYXNlIFNQSVRaX0hFQURTRVQ6CisJCS8qIGVuYWJsZSBhbmQgdW5tdXRlIGhlYWRzZXQgamFjayBlbmFibGUgbWljIGJpYXMsIG11dGUgTCBocCAqLworCQlzbmRfc29jX2RhcG1fc2V0X2VuZHBvaW50KGNvZGVjLCAiSGVhZHBob25lIEphY2siLCAwKTsKKwkJc25kX3NvY19kYXBtX3NldF9lbmRwb2ludChjb2RlYywgIk1pYyBKYWNrIiwgMSk7CisJCXNuZF9zb2NfZGFwbV9zZXRfZW5kcG9pbnQoY29kZWMsICJMaW5lIEphY2siLCAwKTsKKwkJc25kX3NvY19kYXBtX3NldF9lbmRwb2ludChjb2RlYywgIkhlYWRzZXQgSmFjayIsIDEpOworCQlyZXNldF9zY29vcF9ncGlvKCZzcGl0enNjb29wX2RldmljZS5kZXYsIFNQSVRaX1NDUF9NVVRFX0wpOworCQ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