From owner-freebsd-fs@FreeBSD.ORG Mon Jul 29 07:31:50 2013 Return-Path: Delivered-To: freebsd-fs@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id EA02D274; Mon, 29 Jul 2013 07:31:50 +0000 (UTC) (envelope-from varanasisai@gmail.com) Received: from mail-vb0-x229.google.com (mail-vb0-x229.google.com [IPv6:2607:f8b0:400c:c02::229]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 8635922CD; Mon, 29 Jul 2013 07:31:50 +0000 (UTC) Received: by mail-vb0-f41.google.com with SMTP id g17so2580173vbg.28 for ; Mon, 29 Jul 2013 00:31:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:cc:content-type; bh=x/Wa0liEFAFo/KSVMEpO9U/ohxK5wos95gGaxjysA6w=; b=QRJ52eSnFFrMYWT77cX3arbKaHx/4Hw0sfJJ146WS9eyki5hQ3UoDOWmEOhhB0JBOi 6b/aL0r3HrwWo63yFZVfq1Mh/RBDyZgIYcrYSdSUQ6fxDAb5Zolm7JA2kD5IsSec/HqT DSRPrII2koarJarQA9I0hZ9LfFADD8xITfrxfjrsnXV5hhdNU3Sg2YnS3HKSLofxo1YU nyjHh9ou6szpql3aDVS+dEiq3k45HtTgSWoyaPHZwTs6i9hzh61iUIisAa6BPUpu5WsZ iNwAEKUHU0kzVgNP3dbrWJQMEGySRP09NZccqxYH1Agn/Xzj2dpspf0sKXxdIE+V+c+8 yu8A== MIME-Version: 1.0 X-Received: by 10.52.64.243 with SMTP id r19mr1670441vds.76.1375083109553; Mon, 29 Jul 2013 00:31:49 -0700 (PDT) Received: by 10.52.233.9 with HTTP; Mon, 29 Jul 2013 00:31:49 -0700 (PDT) Date: Mon, 29 Jul 2013 13:01:49 +0530 Message-ID: Subject: Kernel Panic - Unix socket communication in kernel module From: varanasi sainath To: freebsd-drivers@freebsd.org, freebsd-fs@freebsd.org, freebsd-questions@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.14 Cc: abgupta@microsoft.com X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 29 Jul 2013 07:31:51 -0000 Hello, I am writing a kernel module in which I am trying to connect to a UNIX socket (UNIX domain sockets use the file system as their address name space). Kernel module (loadable) acts as a client and User mode program acts as server, I have loaded the module using kldload and communication between user and kernel module works fine, when I try to load the kernel module from loader.conf - auto load the kernel module at boot up leads to kernel panic as the file system is not ready and kern_connect fails. How to notify kernel module that File system is ready? (any specific event flags) Is there any specific location for Unix domain socket files? (currently created it under /root/soc/socket ) Using "MODULE_DEPEND" Can I make the module dependent of file system? Thanks. * *