Skip to contentSkip to conversation

remove a group of unused bh functions

PATCH Applied Coywolf Qi Hunt 2 participants 3 messages Jul 28, 2004 – Jul 29, 2004 User-mode Linux (UML)

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 remove a group of unused bh functions

hi jdike, akpm,

This patch removes a group of unused bh functions in um. This 2.2 legacy code should be cleaned up.

-- coywolf

smp.c | 35 -----------------------------------

1 files changed, 35 deletions(-)
arch/um/kernel/smp.c +0 -0
diff -Nrup linux-2.6.8-rc2/arch/um/kernel/smp.c linux-2.6.8-rc2-cy/arch/um/kernel/smp.c
@@ -59,41 +59,6 @@ void smp_send_reschedule(int cpu)
	num_reschedules_sent++;
}

-static void show(char * str)
-{
- int cpu = smp_processor_id();
-
- printk(KERN_INFO "\n%s, CPU %d:\n", str, cpu);
-}
-
-#define MAXCOUNT 100000000
-
-static inline void wait_on_bh(void)
-{
- int count = MAXCOUNT;
- do {
- if (!--count) {
- show("wait_on_bh");
- count = ~0;
- }
- /* nothing .. wait for the other bh's to go away */
- } while (atomic_read(&global_bh_count) != 0);
-}
-
-/*
- * This is called when we want to synchronize with
- * bottom half handlers. We need to wait until
- * no other CPU is executing any bottom half handler.
- *
- * Don't wait if we're already running in an interrupt
- * context or are inside a bh handler. - */ -void synchronize_bh(void)
-{
- if (atomic_read(&global_bh_count) && !in_interrupt())
- wait_on_bh();
-}
-
void smp_send_stop(void)

{
	int i;
Signature · 15 lines
Coywolf Qi Hunt
Homepage http://greatcn.org/~coywolf/
Admin of http://GreatCN.org and http://LoveCN.org



-------------------------------------------------------
This SF.Net email is sponsored by BEA Weblogic Workshop
FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=4721&alloc_id=10040&op=click
_______________________________________________
User-mode-linux-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/user-mode-linux-devel
Applied
#1 lore raw
Quoted 2 lines · [email protected] said:

This patch removes a group of unused bh functions in um. This 2.2 legacy code should be cleaned up.

Applied to my tree, thanks.

Jeff

-------------------------------------------------------
This SF.Net email is sponsored by BEA Weblogic Workshop FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=4721&alloc_id=10040&op=click
_______________________________________________
User-mode-linux-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/user-mode-linux-devel

#2 lore raw

PATCH 1/1 more cleanup on smp.c

Quoted 10 lines · Jeff Dike
Quoted 4 lines · [email protected] said:

This patch removes a group of unused bh functions in um. This 2.2 legacy code should be cleaned up.

Applied to my tree, thanks.

This includes the previous remove_old_bh patch, plus 8 more lines deletions in the same file.

smp.c | 43 -------------------------------------------

1 files changed, 43 deletions(-)
arch/um/kernel/smp.c +0 -0
diff -Nrup linux-2.6.8-rc2/arch/um/kernel/smp.c linux-2.6.8-rc2-cy/arch/um/kernel/smp.c
@@ -33,14 +33,6 @@ EXPORT_SYMBOL(cpu_online_map);
 */

struct cpuinfo_um cpu_data[NR_CPUS];

-spinlock_t um_bh_lock = SPIN_LOCK_UNLOCKED;
-
-atomic_t global_bh_count;
-
-/* Not used by UML */
-unsigned char global_irq_holder = NO_PROC_ID;
-unsigned volatile long global_irq_lock;
-
/* Set when the idlers are all forked */
int smp_threads_ready = 0;

@@ -59,41 +51,6 @@ void smp_send_reschedule(int cpu)

	num_reschedules_sent++;
}

-static void show(char * str)
-{
- int cpu = smp_processor_id();
-
- printk(KERN_INFO "\n%s, CPU %d:\n", str, cpu);
-}
-
-#define MAXCOUNT 100000000
-
-static inline void wait_on_bh(void)
-{
- int count = MAXCOUNT;
- do {
- if (!--count) {
- show("wait_on_bh");
- count = ~0;
- }
- /* nothing .. wait for the other bh's to go away */
- } while (atomic_read(&global_bh_count) != 0);
-}
-
-/*
- * This is called when we want to synchronize with
- * bottom half handlers. We need to wait until
- * no other CPU is executing any bottom half handler.
- *
- * Don't wait if we're already running in an interrupt
- * context or are inside a bh handler. - */ -void synchronize_bh(void)
-{
- if (atomic_read(&global_bh_count) && !in_interrupt())
- wait_on_bh();
-}
-
void smp_send_stop(void)

{
	int i;
Signature · 15 lines
Coywolf Qi Hunt
Homepage http://greatcn.org/~coywolf/
Admin of http://GreatCN.org and http://LoveCN.org



-------------------------------------------------------
This SF.Net email is sponsored by BEA Weblogic Workshop
FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=4721&alloc_id=10040&op=click
_______________________________________________
User-mode-linux-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/user-mode-linux-devel