/* 
* Return class ID and maximum priority. 
* Input argument name is class name.
* Maximum priority is returned in *maxpri.
*/
id_t
schedinfo (name, maxpri)
	char 			*name;
	short 			*maxpri;
{
	pcinfo_t			info;
	tsinfo_t			*tsinfop;
	rtinfo_			*rtinfop;
	(void) strcpy(info.pc_clname, name);
	if (priocntl (0L, 0L, PC_GETCID, &info) == -1L) { 
				return (-1);
	}
	if (strcmp(name, "TS") == 0) {
				tsinfop = (struct tsinfo *) info.pc_clinfo;
				*maxpri = tsinfop->ts_maxupri;
	} else if (strcmp(name, "RT") == 0) {
				rtinfop = (struct rtinfo *) info.pc_clinfo;
				*maxpri = rtinfop->rt_maxpri;
	} else {
				return (-1);
	}
	return (info.pc_cid);
}
