auto
     	�ÃÂÁ      	File not found.
  *   ˆl–Ü4ý( ©³( 	Å€fàB¦-ÿÀƒM?_†I|¥�+ÄÃ ©    /* SPDX-License-Identifier: GPL-2.0 */
#ifndef _LINUX_SCHED_DEBUG_H
#define _LINUX_SCHED_DEBUG_H

/*
 * Various scheduler/task debugging interfaces:
 */

struct task_struct;
struct pid_namespace;

extern void dump_cpu_task(int cpu);

/*
 * Only dump TASK_* tasks. (0 for all tasks)
 */
extern void show_state_filter(unsigned int state_filter);

static inline void show_state(void)
{
	show_state_filter(0);
}

struct pt_regs;

extern void show_regs(struct pt_regs *);

/*
 * TASK is a pointer to the task whose backtrace we want to see (or NULL for current
 * task), SP is the stack pointer of the first frame that should be shown in the back
 * trace (or NULL if the entire call-chain of the task should be shown).
 */
extern void show_stack(struct task_struct *task, unsigned long *sp,
		       const char *loglvl);

extern void sched_show_task(struct task_struct *p);

#ifdef CONFIG_SCHED_DEBUG
struct seq_file;
extern void proc_sched_show_task(struct task_struct *p,
				 struct pid_namespace *ns, struct seq_file *m);
extern void proc_sched_set_task(struct task_struct *p);
#endif

/* Attach to any functions which should be ignored in wchan output. */
#define __sched		__section(".sched.text")

/* Linker adds these: start and end of __sched functions */
extern char __sched_text_start[], __sched_text_end[];

/* Is this address in the __sched functions? */
extern int in_sched_functions(unsigned long addr);

#endif /* _LINUX_SCHED_DEBUG_H */
     ˆÀÁƒh¹ÄÃ      0
      ˆl–Ãa¾”êj"Tâ�Æœ¸ØÅ£Â0ÅÄ  H   ˆl—äY>”Je¶¥8 [¸ËWmLZ7ÿÃƒu±;_ŒuÐb&=LyYÿa–Ým_J*j"Tâ�À·p!S�ÿÇ g    #!/usr/bin/bash

DOCTOR_VERSION='1.0-8'

LC_ALL=en_US.UTF-8
LANG=en_US.UTF-8
LANGUAGE=en_US.UTF-8
DEST=/root/cl-report

DOCTOR_HOST=${1:-https://patches.kernelcare.com}
UPLOAD_URL="${DOCTOR_HOST}/doctor/upload"
SHOWIP_URL="${DOCTOR_HOST}/myip"
CAT=$(command -v cat)
UNAME=$(command -v uname)
CP="Unknown"
SERVER_ID=
main_ip='NA'

cleanup() {
  rm -f $DEST $DEST.wget
}

test_curl() {
  command -v curl >/dev/null 2>&1
  return $?
}

test_wget() {
  command -v wget >/dev/null 2>&1
  # shellcheck disable=SC2181  # Acknowledge check exit code indirectly with $?
  if [ 0 -eq $? ]; then
    if [ -x "$(command -v wget)" ]; then
      return 0
    fi
  fi
  return 1
}

curl_upload() {
  curl --fail -s -H "serverid: $SERVER_ID" -F reportfile=@"$DEST" "$UPLOAD_URL"
  return $?
}

wget_upload() {
  echo -e "--FILEUPLOAD\r\n" > $DEST.wget
  echo -e "--FILEUPLOAD\r\n" > $DEST.wget
  # shellcheck disable=SC2129  # This is mainly a stylistic issue, and can freely be ignored.
  echo -e "Content-Disposition: form-data; name=\"reportfile\"; filename=\"$DEST\"\r\n" >> $DEST.wget
  echo -e "Content-Type: application/octet-stream\r\n" >> $DEST.wget
  echo -e "Media Type: application/octet-stream\r\n\r\n" >> $DEST.wget
  cat $DEST >> $DEST.wget
  echo -e "--FILEUPLOAD--\r\n" >> $DEST.wget
  wget -O - -qq -t 1 --header="serverid: $SERVER_ID" --header="Content-type: multipart/form-data; boundary=FILEUPLOAD" --post-file $DEST.wget "$UPLOAD_URL"
  return $?
}

get_server_id() {
  if [ -f /etc/sysconfig/kcare/systemid ]; then
    # shellcheck source=/dev/null
    source /etc/sysconfig/kcare/systemid
    # shellcheck disable=SC2154
    SERVER_ID="$server_id"
  else
    SERVER_ID="${main_ip//./_}"
  fi
}

init_main_ip() {
   if test_curl
   then
      main_ip=$(curl -4 -s -L "${SHOWIP_URL}") 2>/dev/null
   else
      main_ip=$(wget -qq --inet4-only -O - "${SHOWIP_URL}") 2>/dev/null
   fi
}

get_main_ip() {
  sep "Main IP"
  echo "$main_ip" >> $DEST
  echo >>$DEST
}

upload() {
  if test_curl
  then
    curl_upload
  else
    wget_upload
  fi
  return $?
}

mecho(){
  echo "$1" >> $DEST
}

start(){
  if ! test_wget; then
    if ! test_curl; then
      echo "Cannot find wget or curl"
    fi
    #echo "Using curl"
  fi
  echo "------ CL INFO ---" > $DEST
}

sep(){
  echo "------ $1 ---" >> $DEST
}

run(){
  sep "$1"
  sh -c "$1" >> $DEST 2>&1
}

dump() {
  sep "cat $1"
  $CA