From mboxrd@z Thu Jan 1 00:00:00 1970 References: <20210220055311.23826-1-hongzhan.chen@intel.com> <6030D8D3.9030108@kylinos.cn> From: Philippe Gerum Subject: Re: [PATCH 1/5] cobalt/rtdm: add new interface to init task on specified cpu In-reply-to: Date: Mon, 22 Feb 2021 10:16:02 +0100 Message-ID: <87r1l831kd.fsf@xenomai.org> MIME-Version: 1.0 Content-Type: text/plain List-Id: Discussions about the Xenomai project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Chen, Hongzhan" Cc: chensong , xenomai@xenomai.org Chen, Hongzhan via Xenomai writes: >>-----Original Message----- >>From: chensong >>Sent: Saturday, February 20, 2021 5:40 PM >>To: Chen, Hongzhan ; xenomai@xenomai.org >>Subject: Re: [PATCH 1/5] cobalt/rtdm: add new interface to init task on specified cpu >> >>why do we need a new interface instead of adding a new parameter(cpu) in >>old interface, in this case rtdm_task_init. >> >>For backward compatibility? > > We discussed it about introducing rtdm_task_init_on_cpu in [1]. Actually most of contents of > rtdm_task_init_on_cpu is really same with rtdm_task_init except cpu affinity. But rtdm_task_init > was already called by several drivers such as net and testing. If we modify definition of > rtdm_task_init , we have to modify all of these drivers that calling rtdm_task_init. > > [1]: https://xenomai.org/pipermail/xenomai/2021-February/044250.html Agreed. Not to speak of the custom drivers in the field, which would break at build due to a new prototype of rtdm_task_init(). Besides, adding such a variant matches the mainline kernel naming scheme (kthread_create vs kthread_create_on_node vs kthread_create_on_cpu). -- Philippe.