Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id ; Fri, 11 Oct 2002 10:17:11 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id ; Fri, 11 Oct 2002 10:17:10 -0400 Received: from email.gcom.com ([206.221.230.194]:60621 "EHLO gcom.com") by vger.kernel.org with ESMTP id ; Fri, 11 Oct 2002 10:17:08 -0400 Message-Id: <5.1.0.14.2.20021011091840.02695808@localhost> X-Mailer: QUALCOMM Windows Eudora Version 5.1 Date: Fri, 11 Oct 2002 09:22:09 -0500 To: "Petr Vandrovec" , Arjan van de Ven From: David Grothe Subject: Re: [Linux-streams] Re: [PATCH] Re: export of sys_call_tabl Cc: hch@infradead.org, linux-kernel@vger.kernel.org, LiS , Dave Miller , bidulock@openss7.org In-Reply-To: <43B789B00E8@vcnet.vc.cvut.cz> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=====================_1787956465==_" Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 4727 Lines: 73 --=====================_1787956465==_ Content-Type: text/plain; charset="us-ascii"; format=flowed Here is a proposed "final" patch for the streams hooks. I think that it takes into account all suggestions. I put the prototype in linux/sys.h. This is for stock 2.4.19, and has been tested. -- Dave --=====================_1787956465==_ Content-Type: text/plain; name="stock-i386-2.4.19.txt"; x-mac-type="42494E41"; x-mac-creator="74747874" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="stock-i386-2.4.19.txt" LS0tIGFyY2gvaTM4Ni9rZXJuZWwvZW50cnkuUy5vcmlnCTIwMDItMDgtMDIgMTk6Mzk6NDIuMDAw MDAwMDAwIC0wNTAwCisrKyBhcmNoL2kzODYva2VybmVsL2VudHJ5LlMJMjAwMi0xMC0wOCAxNTo0 MzowOC4wMDAwMDAwMDAgLTA1MDAKQEAgLTU4NCw4ICs1ODQsOCBAQAogCS5sb25nIFNZTUJPTF9O QU1FKHN5c19jYXBzZXQpICAgICAgICAgICAvKiAxODUgKi8KIA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iB0aGUga2VybmVsCisgKiBzb3VyY2UgdHJlZS4KKyAqLworI2lmICFk ZWZpbmVkKF9fQVNTRU1CTFlfXykKK2V4dGVybiBpbnQKK3JlZ2lzdGVyX3N0cmVhbXNfY2FsbHMo aW50ICgqcHV0cG1zZykgKGludCwgdm9pZCAqLCB2b2lkICosIGludCwgaW50KSwKKwkJICAgICAg IGludCAoKmdldHBtc2cpIChpbnQsIHZvaWQgKiwgdm9pZCAqLCBpbnQsIGludCkpIDsKKworI2Vu ZGlmCQkJLyogX19BU1NFTUJMWV9fICovCiAjZW5kaWYK --=====================_1787956465==_-- - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/