Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id ; Thu, 22 Nov 2001 15:13:24 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id ; Thu, 22 Nov 2001 15:13:15 -0500 Received: from [208.129.208.52] ([208.129.208.52]:48398 "EHLO xmailserver.org") by vger.kernel.org with ESMTP id ; Thu, 22 Nov 2001 15:13:04 -0500 Date: Thu, 22 Nov 2001 12:22:47 -0800 (PST) From: Davide Libenzi X-X-Sender: davide@blue1.dev.mcafeelabs.com To: Ingo Molnar cc: linux-kernel@vger.kernel.org, Subject: Re: [patch] sched_[set|get]_affinity() syscall, 2.4.15-pre9 In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 22 Nov 2001, Ingo Molnar wrote: > > the attached set-affinity-A1 patch is relative to the scheduler > fixes/cleanups in 2.4.15-pre9. It implements the following two > new system calls: > > asmlinkage int sys_sched_set_affinity(pid_t pid, unsigned int mask_len, > unsigned long *new_mask_ptr); > > asmlinkage int sys_sched_get_affinity(pid_t pid, unsigned int > *user_mask_len_ptr, unsigned long *user_mask_ptr); I think that maybe it's better to have a new type : typedef whatever-is-appropriate cpu_affinity_t; with a set of macros : CPU_AFFINITY_INIT(aptr) CPU_AFFINITY_SET(aptr, n) CPU_AFFINITY_ISSET(aprt, n) so that we can simplify that interfaces : asmlinkage int sys_sched_set_affinity(pid_t pid, cpu_affinity_t *aptr); asmlinkage int sys_sched_get_affinity(pid_t pid, cpu_affinity_t *aptr); - Davide - 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/