From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.6 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5F96BC4332B for ; Sun, 22 Mar 2020 16:37:48 +0000 (UTC) Received: from shelob.surriel.com (shelob.surriel.com [96.67.55.147]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 2473520724 for ; Sun, 22 Mar 2020 16:37:48 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=kroah.com header.i=@kroah.com header.b="OrPYLXDy"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b="q/TDt1ZO" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 2473520724 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=kroah.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=kernelnewbies-bounces@kernelnewbies.org Received: from localhost ([::1] helo=shelob.surriel.com) by shelob.surriel.com with esmtp (Exim 4.92.3) (envelope-from ) id 1jG3ba-0006uT-Vi; Sun, 22 Mar 2020 12:37:42 -0400 Received: from out3-smtp.messagingengine.com ([66.111.4.27]) by shelob.surriel.com with esmtps (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.92.3) (envelope-from ) id 1jG3bY-0006uN-EU for kernelnewbies@kernelnewbies.org; Sun, 22 Mar 2020 12:37:40 -0400 Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 03DFF5C00F2; Sun, 22 Mar 2020 12:37:39 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute1.internal (MEProxy); Sun, 22 Mar 2020 12:37:39 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kroah.com; h= date:from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; s=fm3; bh=x0nozzg2/ZBQxOdyigh3RH31j6H +gK+ni1NVXJ67GME=; b=OrPYLXDyiUNWcqhvC46VQpPi4LV+2it+Jp5f/DNKFQw a3fUQNyykF7VOzZnj3JDBUS15kAZCsTQS4tikXUhv500ozN7Zdmenlc3g+QSr1P+ 11xQiBSxDJYDJ6NXd9xmLHgLtbIlTTPi8li2/OI5LUuFYrHvZqBa3NBD0yRhE+Ep 4cooZy6Z8x9XFCJUB6PLHQzYOalLek5oLUSfjUMdaioAdLyccrMiOwB8VNpgaK9q IBRnYTEFmDwKtRd+M7/AC5XlveQMiGmkbtLh92HtGVcQiz12KCYrp3i3ly5KaRBK yWdrROIwar+xW+g4dMidNSKhBQPhCoT8BxoZCrlAKOg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm2; bh=x0nozz g2/ZBQxOdyigh3RH31j6H+gK+ni1NVXJ67GME=; b=q/TDt1ZO4p7qRC7QigIoJH 2lS+jrezZQOvBngDspOxDViaz3Z3ROaxPhv0aLISYJsy61ERR+8jKzP88mtHBQ9P 15fQCUVliYi26L8WllvbYeD7C5A6wRrLL2VOOOP0wTJ0SkKxuSpH2CnR+wGZawtl if4/bRfyCcJSxrKu3RjgdQieTjntfF5ilA5nGApDYIfCYPDCgwLkmr7Bmdq+YFY2 BsjH3RhLKQjISAxqLVYu2PxBxOXnpThMFMaXoLmqT3Er2XiczqqlIyT37YX7qn67 UnEhjsraQK9kGdHjaKjy0FygvEtwhW8Rbko6gkGlEnGZ0bknGU3yFba0QgFsK1yA == X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedugedrudegiedgleefucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepfffhvffukfhfgggtuggjsehttdertddttddvnecuhfhrohhmpefirhgvghcu mffjuceoghhrvghgsehkrhhorghhrdgtohhmqeenucfkphepkeefrdekiedrkeelrddutd ejnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepghhr vghgsehkrhhorghhrdgtohhm X-ME-Proxy: Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) by mail.messagingengine.com (Postfix) with ESMTPA id 822EE3061856; Sun, 22 Mar 2020 12:37:38 -0400 (EDT) Date: Sun, 22 Mar 2020 17:37:35 +0100 From: Greg KH To: Tomek The Messenger Subject: Re: Writing framework in kernel Message-ID: <20200322163735.GB96331@kroah.com> References: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: Cc: kernelnewbies@kernelnewbies.org X-BeenThere: kernelnewbies@kernelnewbies.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Learn about the Linux kernel List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: kernelnewbies-bounces@kernelnewbies.org On Sun, Mar 22, 2020 at 05:08:15PM +0100, Tomek The Messenger wrote: > Hi > I am writing some framework for my kernel drivers. I delegated to framework > the code which is common amongs all kernel drivers. So my framework module > core.c has none probe, remove functions. It has also none module_init, > module_exit functions at those are not needed. > 1.) When I do modprobe of my core.ko I got error: > 15.092976] testframework_core: module license 'unspecified' taints kernel. > [ 15.129532] testframework_core : Unknown symbol regmap_write (err 0) > [ 15.129554] testframework_core : Unknown symbol devm_kmalloc (err 0) > [ 15.129573] rstctl_core testframework_core : Unknown symbol > of_property_read_variable_u32_array (err 0) > [ 15.129598] testframework_core : Unknown symbol sysfs_remove_groups (err > 0) > etc > > So I suppose I need to put in my core.c line: > MODULE_LICENSE("GPL v2"); > at the end of file in order to get rid of above problems. I will check if > it helps. Yes, that is what you need to do here, you are trying to access symbols that are GPL-only, and you did not specify the license of your module to the kernel. good luck! greg k-h _______________________________________________ Kernelnewbies mailing list Kernelnewbies@kernelnewbies.org https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies